diff --git a/flake.lock b/flake.lock index 4fa76dc..b4a05c0 100644 --- a/flake.lock +++ b/flake.lock @@ -134,11 +134,11 @@ "zig": "zig" }, "locked": { - "lastModified": 1736210320, - "narHash": "sha256-QnDkQ/s1OWmPj1f+7MFNxQiAPJdHbI1Aft7yM5I+8gQ=", + "lastModified": 1736566108, + "narHash": "sha256-r+FXWU/hfgO3lAHYs9Q03iCShnC42mZd1pnmIIp8Z9k=", "owner": "ghostty-org", "repo": "ghostty", - "rev": "a3837a1e4ee06a183f32d4a622c2cdcd51f73fb8", + "rev": "918ccdba5cc65ccd1fb48a54c71306d869299441", "type": "github" }, "original": { @@ -221,11 +221,11 @@ ] }, "locked": { - "lastModified": 1736204492, - "narHash": "sha256-CoBPRgkUex9Iz6qGSzi/BFVUQjndB0PmME2B6eEyeCs=", + "lastModified": 1736508663, + "narHash": "sha256-ZOaGwa+WnB7Zn3YXimqjmIugAnHePdXCmNu+AHkq808=", "owner": "nix-community", "repo": "home-manager", - "rev": "20665c6efa83d71020c8730f26706258ba5c6b2a", + "rev": "2532b500c3ed2b8940e831039dcec5a5ea093afc", "type": "github" }, "original": { @@ -266,11 +266,11 @@ "treefmt-nix": "treefmt-nix" }, "locked": { - "lastModified": 1736233375, - "narHash": "sha256-I6fqKdaoKOVU33SyPv+MuxWRiOs+PXQTO94aCLA3rAc=", + "lastModified": 1736553940, + "narHash": "sha256-xicqHwvq2S/Y36DwcY+xGy6+4jdFT78bclBhwjs4KJY=", "owner": "nix-community", "repo": "neovim-nightly-overlay", - "rev": "721f5f602b876a3ee21be04f68ab3cedf162e7f6", + "rev": "b2237869f288c278b6fd429445d460cb44a0e788", "type": "github" }, "original": { @@ -282,11 +282,11 @@ "neovim-src": { "flake": false, "locked": { - "lastModified": 1736193797, - "narHash": "sha256-5S4RnwKfa5nn/r+8OsMtfgD6TEA5P6cWKti76A0zIMc=", + "lastModified": 1736553525, + "narHash": "sha256-Kfx1r0yVTTa83EdP7Ta5ValnXy4ak3F10hHCymDAU7o=", "owner": "neovim", "repo": "neovim", - "rev": "b6ab294838421afb6932c52dd6e6d35d571e621d", + "rev": "fbe546e25d21f3184814d696c329d23d146bd615", "type": "github" }, "original": { @@ -302,11 +302,11 @@ ] }, "locked": { - "lastModified": 1736047960, - "narHash": "sha256-hutd85FA1jUJhhqBRRJ+u7UHO9oFGD/RVm2x5w8WjVQ=", + "lastModified": 1736440205, + "narHash": "sha256-QJgTI//KEGuEJC6FDxuI9Dq8PewIpnxD2NVx2/OHbfc=", "owner": "nix-community", "repo": "nix-index-database", - "rev": "816a6ae88774ba7e74314830546c29e134e0dffb", + "rev": "a2200b499efa01ca8646173e94cdfcc93188f2b8", "type": "github" }, "original": { @@ -349,11 +349,11 @@ }, "nixpkgs-stable_2": { "locked": { - "lastModified": 1736061677, - "narHash": "sha256-DjkQPnkAfd7eB522PwnkGhOMuT9QVCZspDpJJYyOj60=", + "lastModified": 1736200483, + "narHash": "sha256-JO+lFN2HsCwSLMUWXHeOad6QUxOuwe9UOAF/iSl1J4I=", "owner": "nixos", "repo": "nixpkgs", - "rev": "cbd8ec4de4469333c82ff40d057350c30e9f7d36", + "rev": "3f0a8ac25fb674611b98089ca3a5dd6480175751", "type": "github" }, "original": { @@ -381,11 +381,11 @@ }, "nixpkgs-unstable_2": { "locked": { - "lastModified": 1736134818, - "narHash": "sha256-30sOEZ8CFK2nTTMdkhaNrfVlIi3rWTNV0Z5z+NmpFNI=", + "lastModified": 1736420959, + "narHash": "sha256-dMGNa5UwdtowEqQac+Dr0d2tFO/60ckVgdhZU9q2E2o=", "owner": "nixos", "repo": "nixpkgs", - "rev": "3df3c47c19dc90fec35359e89ffb52b34d2b0e94", + "rev": "32af3611f6f05655ca166a0b1f47b57c762b5192", "type": "github" }, "original": { @@ -397,11 +397,11 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1736042175, - "narHash": "sha256-jdd5UWtLVrNEW8K6u5sy5upNAFmF3S4Y+OIeToqJ1X8=", + "lastModified": 1736320768, + "narHash": "sha256-nIYdTAiKIGnFNugbomgBJR+Xv5F1ZQU+HfaBqJKroC0=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "bf689c40d035239a489de5997a4da5352434632e", + "rev": "4bc9c909d9ac828a039f288cf872d16d38185db8", "type": "github" }, "original": { @@ -413,11 +413,11 @@ }, "nixpkgs_3": { "locked": { - "lastModified": 1736012469, - "narHash": "sha256-/qlNWm/IEVVH7GfgAIyP6EsVZI6zjAx1cV5zNyrs+rI=", + "lastModified": 1736344531, + "narHash": "sha256-8YVQ9ZbSfuUk2bUf2KRj60NRraLPKPS0Q4QFTbc+c2c=", "owner": "nixos", "repo": "nixpkgs", - "rev": "8f3e1f807051e32d8c95cd12b9b421623850a34d", + "rev": "bffc22eb12172e6db3c5dde9e3e5628f8e3e7912", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index 1bc8a36..35ccf56 100644 --- a/flake.nix +++ b/flake.nix @@ -70,6 +70,7 @@ packages = with pkgs; [ just nh + nil nixd nixfmt-rfc-style ]; diff --git a/home/common/nvim/blink-cmp.lua b/home/common/nvim/blink-cmp.lua index b59fe58..26531e4 100644 --- a/home/common/nvim/blink-cmp.lua +++ b/home/common/nvim/blink-cmp.lua @@ -1,9 +1,10 @@ require 'blink-cmp'.setup({ keymap = { preset = 'enter', - -- preset = 'super-tab', - [""] = { "scroll_documentation_down" }, - [""] = { "scroll_documentation_up" }, + [''] = { 'select_next', 'fallback' }, + [''] = { 'select_prev', 'fallback' }, + [''] = { 'scroll_documentation_down', 'fallback' }, + [''] = { 'scroll_documentation_up', 'fallback' }, }, completion = { accept = { @@ -16,15 +17,35 @@ require 'blink-cmp'.setup({ window = { border = 'rounded', }, }, - ghost_text = { enabled = true }, + ghost_text = { enabled = false }, list = { - selection = { preselect = false, auto_insert = false }, + selection = { + preselect = false, + auto_insert = false + }, }, menu = { - auto_show = false, - }, + auto_show = true, + direction_priority = { 'n' }, + draw = { + components = { + kind_icon = { + ellipsis = false, + text = function(ctx) + local kind_icon, _, _ = require('mini.icons').get('lsp', ctx.kind) + return kind_icon + end, + -- Optionally, you may also use the highlights from mini.icons + highlight = function(ctx) + local _, hl, _ = require('mini.icons').get('lsp', ctx.kind) + return hl + end, + } + } + } + } }, fuzzy = { @@ -39,7 +60,7 @@ require 'blink-cmp'.setup({ }, sources = { - default = { 'lsp', 'codeium', 'buffer' }, + default = { 'lsp', 'codeium' }, cmdline = {}, providers = { codeium = { diff --git a/home/common/nvim/default.nix b/home/common/nvim/default.nix index 4312729..7056678 100644 --- a/home/common/nvim/default.nix +++ b/home/common/nvim/default.nix @@ -124,6 +124,27 @@ in ''; } + { + plugin = pkgs.vimUtils.buildVimPlugin { + name = "neocodeium"; + src = pkgs.fetchFromGitHub { + owner = "monkoose"; + repo = "neocodeium"; + rev = "4da81528468b33585c411f31eb390dce573ccb14"; # v1.8.0 + hash = "sha256-1n9nNqBNwNDSzbAkm8eB4HZLNy5HmMg25jPwQAnW5OU="; + }; + doCheck = false; + }; + type = "lua"; + config = '' + local neocodeium =require('neocodeium') + neocodeium.setup() + vim.keymap.set("i", "", neocodeium.accept, { remap = true }) + vim.keymap.set("i", "", neocodeium.accept, { remap = true }) + vim.keymap.set("i", "", neocodeium.cycle_or_complete, { remap = true }) + ''; + } + { plugin = pkgs.vimUtils.buildVimPlugin { name = "diagflow"; diff --git a/home/common/nvim/init.lua b/home/common/nvim/init.lua index 8682273..4487604 100644 --- a/home/common/nvim/init.lua +++ b/home/common/nvim/init.lua @@ -65,7 +65,7 @@ vim.o.showcmd = false vim.o.showmode = false vim.o.smoothscroll = true vim.o.splitkeep = "screen" -vim.o.timeoutlen = 10 +vim.o.timeoutlen = 1 vim.o.timeout = true vim.o.updatetime = 50