Skip to content

Commit 9d2e376

Browse files
committed
update opencode, load env
1 parent 83d7ea0 commit 9d2e376

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

lua/custom/plugins/enable/opencode.lua

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,18 +25,20 @@ return {
2525
},
2626
},
2727
config = function()
28+
local opencode_cmd = [[zsh -ic 'opencode --port']]
29+
2830
---@type opencode.Opts
2931
vim.g.opencode_opts = {
3032
server = {
3133
start = function()
32-
require('opencode.terminal').open('opencode --port', {
34+
require('opencode.terminal').open(opencode_cmd, {
3335
split = 'right',
3436
width = math.max(40, math.floor(vim.o.columns * 0.4)),
3537
})
3638
end,
3739
stop = function() require('opencode.terminal').close() end,
3840
toggle = function()
39-
require('opencode.terminal').toggle('opencode --port', {
41+
require('opencode.terminal').toggle(opencode_cmd, {
4042
split = 'right',
4143
width = math.max(40, math.floor(vim.o.columns * 0.4)),
4244
})

0 commit comments

Comments
 (0)