diff --git a/lua/configs/conform.lua b/lua/configs/conform.lua index 14e3013..e12845e 100644 --- a/lua/configs/conform.lua +++ b/lua/configs/conform.lua @@ -5,10 +5,10 @@ local options = { html = { "prettier" }, }, - format_on_save = { - timeout_ms = 500, - lsp_fallback = true, - }, + -- format_on_save = { + -- timeout_ms = 500, + -- lsp_fallback = true, + -- }, } return options diff --git a/lua/plugins/init.lua b/lua/plugins/init.lua index 2b503db..5e8484d 100644 --- a/lua/plugins/init.lua +++ b/lua/plugins/init.lua @@ -1,7 +1,7 @@ return { { "stevearc/conform.nvim", - event = "BufWritePre", + -- event = "BufWritePre", opts = require "configs.conform", }, @@ -180,9 +180,7 @@ return { }, config = function() ---@type opencode.Opts - vim.g.opencode_opts = { - -- Your configuration, if any; goto definition on the type or field for details - } + vim.g.opencode_opts = {} vim.o.autoread = true -- Required for `opts.events.reload` @@ -190,37 +188,30 @@ return { return require "opencode" end - -- Toggle Opencode panel vim.keymap.set({ "n", "t" }, "ct", function() o().toggle() end, { desc = "Opencode: Toggle panel" }) - -- Ask (submit selection) vim.keymap.set({ "n", "x" }, "ca", function() o().ask("@this: ", { submit = true }) end, { desc = "Opencode: Ask selection" }) - -- Execute action vim.keymap.set({ "n", "x" }, "ce", function() o().select() end, { desc = "Opencode: Execute action" }) - -- Send selection vim.keymap.set({ "n", "x" }, "cs", function() return o().operator "@this " end, { expr = true, desc = "Opencode: Send selection" }) - -- Send current line vim.keymap.set("n", "cl", function() return o().operator "@this " .. "_" end, { expr = true, desc = "Opencode: Send line" }) - -- Scroll up in Opencode panel vim.keymap.set("n", "cu", function() o().command "session.half.page.up" end, { desc = "Opencode: Scroll up" }) - -- Scroll down in Opencode panel vim.keymap.set("n", "cd", function() o().command "session.half.page.down" end, { desc = "Opencode: Scroll down" })