From 8f25c2fc0bb3aee6a30cdaed1d571fcf948b4f98 Mon Sep 17 00:00:00 2001 From: zackartz Date: Tue, 14 May 2024 14:32:28 -0400 Subject: [PATCH] 584 current 2024-05-14 14:32:25 24.05.20240512.2057814 6.8.6-zen1 * --- hosts/earth/configuration.nix | 17 +++++++++-------- .../vim/config/lua/core/keymaps.lua | 2 ++ .../home-manager/vim/config/lua/lsp/autocmd.lua | 14 +++++++------- .../home-manager/vim/config/lua/lsp/keymaps.lua | 8 ++++---- .../vim/config/lua/plugins/editor/nvim-cmp.lua | 3 --- .../vim/config/lua/plugins/tools/vim-dadbod.lua | 9 +++++++++ 6 files changed, 31 insertions(+), 22 deletions(-) diff --git a/hosts/earth/configuration.nix b/hosts/earth/configuration.nix index 6b77784..9b4d2ce 100644 --- a/hosts/earth/configuration.nix +++ b/hosts/earth/configuration.nix @@ -44,14 +44,15 @@ services.fstrim.enable = true; services.mullvad-vpn.enable = true; - systemd.services."mullvad-daemon".postStart = let - mullvad = config.services.mullvad-vpn.package; - in '' - while ! ${mullvad}/bin/mullvad status >/dev/null; do sleep 1; done - ${mullvad}/bin/mullvad auto-connect set on - ${mullvad}/bin/mullvad tunnel set ipv6 on - ${mullvad}/bin/mullvad connect - ''; + # disable autoconnect for now + # systemd.services."mullvad-daemon".postStart = let + # mullvad = config.services.mullvad-vpn.package; + # in '' + # while ! ${mullvad}/bin/mullvad status >/dev/null; do sleep 1; done + # ${mullvad}/bin/mullvad auto-connect set on + # ${mullvad}/bin/mullvad tunnel set ipv6 on + # ${mullvad}/bin/mullvad connect + # ''; services.transmission = { enable = true; diff --git a/modules/home-manager/vim/config/lua/core/keymaps.lua b/modules/home-manager/vim/config/lua/core/keymaps.lua index 5504027..63d012e 100644 --- a/modules/home-manager/vim/config/lua/core/keymaps.lua +++ b/modules/home-manager/vim/config/lua/core/keymaps.lua @@ -34,6 +34,8 @@ return { -- Neotree [l("e")] = { cmd("Neotree toggle"), fmt("FileTree", "Toggle Neotree") }, + [l("ng")] = { cmd("Neogit"), fmt("Git", "Open Neogit") }, + -- move.nvim [""] = { cmd("MoveLine(1)"), "Move line down" }, [""] = { cmd("MoveLine(-1)"), "Move line up" }, diff --git a/modules/home-manager/vim/config/lua/lsp/autocmd.lua b/modules/home-manager/vim/config/lua/lsp/autocmd.lua index 9ebcdfe..fa7e718 100644 --- a/modules/home-manager/vim/config/lua/lsp/autocmd.lua +++ b/modules/home-manager/vim/config/lua/lsp/autocmd.lua @@ -1,13 +1,13 @@ local lsp = require("lsp.functions") return { - ["textDocument/codeLens"] = { - event = { "BufEnter", "InsertLeave" }, - opts = { - group = vim.api.nvim_create_augroup("LspCodelens", {}), - callback = lsp.refresh_codelens, - }, - }, + -- ["textDocument/codeLens"] = { + -- event = { "BufEnter", "InsertLeave" }, + -- opts = { + -- group = vim.api.nvim_create_augroup("LspCodelens", {}), + -- callback = lsp.refresh_codelens, + -- }, + -- }, ["textDocument/formatting"] = { event = "BufWritePost", opts = { diff --git a/modules/home-manager/vim/config/lua/lsp/keymaps.lua b/modules/home-manager/vim/config/lua/lsp/keymaps.lua index 470a7ee..d56cc4f 100644 --- a/modules/home-manager/vim/config/lua/lsp/keymaps.lua +++ b/modules/home-manager/vim/config/lua/lsp/keymaps.lua @@ -39,10 +39,10 @@ return { ["textDocument/typeDefinition"] = { ["gT"] = { lsp.type_definition, "Go to type definition" }, }, - ["textDocument/codeLens"] = { - ["ll"] = { lsp.run_codelens, fmt("Run", "Run codelens") }, - ["lL"] = { lsp.refresh_codelens, fmt("Restart", "Refresh codelens") }, - }, + -- ["textDocument/codeLens"] = { + -- ["ll"] = { lsp.run_codelens, fmt("Run", "Run codelens") }, + -- ["lL"] = { lsp.refresh_codelens, fmt("Restart", "Refresh codelens") }, + -- }, ["workspace/symbol"] = { ["ls"] = { lsp.symbols, fmt("Symbol", "Workspace symbols") }, }, diff --git a/modules/home-manager/vim/config/lua/plugins/editor/nvim-cmp.lua b/modules/home-manager/vim/config/lua/plugins/editor/nvim-cmp.lua index eca76b2..79213e3 100644 --- a/modules/home-manager/vim/config/lua/plugins/editor/nvim-cmp.lua +++ b/modules/home-manager/vim/config/lua/plugins/editor/nvim-cmp.lua @@ -92,8 +92,6 @@ return { return end - local catppuccin = require("catppuccin") - return { snippet = { expand = function(args) @@ -113,7 +111,6 @@ return { sources = cmp.config.sources({ { name = "nvim_lsp", priority = 1000 }, { name = "crates", priority = 1000 }, - { name = "vim-dadbod-completion", priority = 1000 }, { name = "luasnip", priority = 750 }, { name = "buffer", priority = 500 }, { name = "path", priority = 250 }, diff --git a/modules/home-manager/vim/config/lua/plugins/tools/vim-dadbod.lua b/modules/home-manager/vim/config/lua/plugins/tools/vim-dadbod.lua index 79d8528..2b6cdc8 100644 --- a/modules/home-manager/vim/config/lua/plugins/tools/vim-dadbod.lua +++ b/modules/home-manager/vim/config/lua/plugins/tools/vim-dadbod.lua @@ -16,5 +16,14 @@ return { config = function() vim.g.db_ui_notification_width = 1 vim.g.db_ui_debug = 1 + + local cmp = require("cmp") + + cmp.setup.filetype({ "sql" }, { + sources = { + { name = "vim-dadbod-completion" }, + { name = "buffer" }, + }, + }) end, }