From 6855a707d4154b4d3b55d9b987cbf1be9c1912b8 Mon Sep 17 00:00:00 2001 From: Mykhailo Nikiforov Date: Thu, 16 Apr 2026 18:14:54 +0300 Subject: [PATCH] feat: update plugins, flake --- config/default.nix | 5 +-- config/modules/plugins/lightline.nix | 9 ++++++ config/modules/plugins/lualine.nix | 9 ++++++ config/modules/plugins/mini.nix | 1 - config/modules/plugins/snacks.nix | 19 +++++++---- config/modules/plugins/treesitter.nix | 44 +++++++++++++++++++++---- config/options.nix | 11 +++++++ flake.lock | 46 +++++++++++++-------------- 8 files changed, 104 insertions(+), 40 deletions(-) create mode 100644 config/modules/plugins/lightline.nix create mode 100644 config/modules/plugins/lualine.nix diff --git a/config/default.nix b/config/default.nix index 3764ebc..07029cc 100644 --- a/config/default.nix +++ b/config/default.nix @@ -6,19 +6,16 @@ ./modules/plugins/lsp - ./modules/plugins/airline.nix ./modules/plugins/blink-cmp.nix ./modules/plugins/bufferline.nix ./modules/plugins/conform-nvim.nix ./modules/plugins/fzf-lua.nix ./modules/plugins/gitsigns.nix + ./modules/plugins/lualine.nix ./modules/plugins/mini.nix - # ./modules/plugins/neotree.nix ./modules/plugins/oil.nix ./modules/plugins/snacks.nix - ./modules/plugins/tmux-navigator.nix ./modules/plugins/treesitter.nix - ./modules/plugins/undotree.nix ./modules/plugins/venv-selector.nix ./modules/plugins/which-key.nix ]; diff --git a/config/modules/plugins/lightline.nix b/config/modules/plugins/lightline.nix new file mode 100644 index 0000000..c6ce78b --- /dev/null +++ b/config/modules/plugins/lightline.nix @@ -0,0 +1,9 @@ +{ + plugins.lightline = { + enable = true; + settings = { + colorscheme = "catppuccin"; + tabline = false; + }; + }; +} diff --git a/config/modules/plugins/lualine.nix b/config/modules/plugins/lualine.nix new file mode 100644 index 0000000..cc472e7 --- /dev/null +++ b/config/modules/plugins/lualine.nix @@ -0,0 +1,9 @@ +{ + plugins.lualine = { + enable = true; + settings.options = { + theme = "catppuccin"; + globalstatus = true; + }; + }; +} diff --git a/config/modules/plugins/mini.nix b/config/modules/plugins/mini.nix index 991a0fa..b7c2ca0 100644 --- a/config/modules/plugins/mini.nix +++ b/config/modules/plugins/mini.nix @@ -5,7 +5,6 @@ modules = { icons = { }; comment = { }; - diff = { }; }; }; } diff --git a/config/modules/plugins/snacks.nix b/config/modules/plugins/snacks.nix index 36c25a6..4a59da1 100644 --- a/config/modules/plugins/snacks.nix +++ b/config/modules/plugins/snacks.nix @@ -4,14 +4,14 @@ enable = true; settings = { bigfile.enabled = true; - notifier.enabled = true; - quickfile.enabled = true; statuscolumn.enabled = true; - words.enabled = true; lazygit.enabled = true; - picker.enabled = true; - indent.enabled = true; - scope.enabled = true; + picker = { + enabled = true; + matcher = { + frecency = true; + }; + }; }; }; @@ -436,6 +436,13 @@ desc = "Delete Buffer"; }; } + { + key = "bo"; + action = lib.nixvim.mkRaw "function() Snacks.bufdelete.other() end"; + options = { + desc = "Delete Other Buffers"; + }; + } { key = "cR"; action = lib.nixvim.mkRaw "function() Snacks.rename.rename_file() end"; diff --git a/config/modules/plugins/treesitter.nix b/config/modules/plugins/treesitter.nix index c66de14..f21a6ec 100644 --- a/config/modules/plugins/treesitter.nix +++ b/config/modules/plugins/treesitter.nix @@ -3,7 +3,6 @@ plugins = { treesitter = { enable = true; - settings = { indent = { enable = true; @@ -17,12 +16,48 @@ grammarPackages = pkgs.vimPlugins.nvim-treesitter.allGrammars; }; + # Show sticky context window at top treesitter-context = { - enable = false; + enable = true; + settings = { + max_lines = 5; + mode = "topline"; + trim_scope = "outer"; + }; + }; + + # highlight scoped function + indent-blankline = { + enable = true; + settings = { + exclude = { + buftypes = [ + "terminal" + "quickfix" + ]; + filetypes = [ + "" + "checkhealth" + "help" + "lspinfo" + "packer" + "TelescopePrompt" + "TelescopeResults" + ]; + }; + indent = { + char = "│"; + }; + scope = { + show_end = false; + show_exact_scope = true; + show_start = true; + }; + }; }; treesitter-textobjects = { - enable = true; + enable = false; settings = { select = { enable = true; @@ -31,7 +66,4 @@ }; }; }; - extraConfigLua = '' - local parser_config = require("nvim-treesitter.parsers").get_parser_configs() - ''; } diff --git a/config/options.nix b/config/options.nix index c7f4bf5..df65af0 100644 --- a/config/options.nix +++ b/config/options.nix @@ -62,6 +62,12 @@ scrolloff = 5; }; + # Enable limit colomn + opts.colorcolumn = "80,120"; + opts.wrap = false; + # This info is displayed in lightline + opts.showmode = false; + diagnostic.settings = { update_in_insert = true; severity_sort = true; @@ -112,4 +118,9 @@ # Comment.underline = true; # Comment.bold = true; # }; + + withNodeJs = false; + withPerl = false; + withPython3 = false; + withRuby = false; } diff --git a/flake.lock b/flake.lock index 860ecd6..5dd7284 100644 --- a/flake.lock +++ b/flake.lock @@ -5,11 +5,11 @@ "nixpkgs-lib": "nixpkgs-lib" }, "locked": { - "lastModified": 1765835352, - "narHash": "sha256-XswHlK/Qtjasvhd1nOa1e8MgZ8GS//jBoTqWtrS1Giw=", + "lastModified": 1775087534, + "narHash": "sha256-91qqW8lhL7TLwgQWijoGBbiD4t7/q75KTi8NxjVmSmA=", "owner": "hercules-ci", "repo": "flake-parts", - "rev": "a34fae9c08a15ad73f295041fec82323541400a9", + "rev": "3107b77cd68437b9a76194f0f7f9c55f2329ca5b", "type": "github" }, "original": { @@ -26,11 +26,11 @@ ] }, "locked": { - "lastModified": 1765835352, - "narHash": "sha256-XswHlK/Qtjasvhd1nOa1e8MgZ8GS//jBoTqWtrS1Giw=", + "lastModified": 1768135262, + "narHash": "sha256-PVvu7OqHBGWN16zSi6tEmPwwHQ4rLPU9Plvs8/1TUBY=", "owner": "hercules-ci", "repo": "flake-parts", - "rev": "a34fae9c08a15ad73f295041fec82323541400a9", + "rev": "80daad04eddbbf5a4d883996a73f3f542fa437ac", "type": "github" }, "original": { @@ -87,11 +87,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1772047000, - "narHash": "sha256-7DaQVv4R97cii/Qdfy4tmDZMB2xxtyIvNGSwXBBhSmo=", + "lastModified": 1776067740, + "narHash": "sha256-B35lpsqnSZwn1Lmz06BpwF7atPgFmUgw1l8KAV3zpVQ=", "owner": "nixos", "repo": "nixpkgs", - "rev": "1267bb4920d0fc06ea916734c11b0bf004bbe17e", + "rev": "7e495b747b51f95ae15e74377c5ce1fe69c1765f", "type": "github" }, "original": { @@ -103,11 +103,11 @@ }, "nixpkgs-lib": { "locked": { - "lastModified": 1765674936, - "narHash": "sha256-k00uTP4JNfmejrCLJOwdObYC9jHRrr/5M/a/8L2EIdo=", + "lastModified": 1774748309, + "narHash": "sha256-+U7gF3qxzwD5TZuANzZPeJTZRHS29OFQgkQ2kiTJBIQ=", "owner": "nix-community", "repo": "nixpkgs.lib", - "rev": "2075416fcb47225d9b68ac469a5c4801a9c4dd85", + "rev": "333c4e0545a6da976206c74db8773a1645b5870a", "type": "github" }, "original": { @@ -118,15 +118,15 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1772047000, - "narHash": "sha256-7DaQVv4R97cii/Qdfy4tmDZMB2xxtyIvNGSwXBBhSmo=", - "owner": "nixos", + "lastModified": 1768323494, + "narHash": "sha256-yBXJLE6WCtrGo7LKiB6NOt6nisBEEkguC/lq/rP3zRQ=", + "owner": "NixOS", "repo": "nixpkgs", - "rev": "1267bb4920d0fc06ea916734c11b0bf004bbe17e", + "rev": "2c3e5ec5df46d3aeee2a1da0bfedd74e21f4bf3a", "type": "github" }, "original": { - "owner": "nixos", + "owner": "NixOS", "ref": "nixos-25.11", "repo": "nixpkgs", "type": "github" @@ -140,11 +140,11 @@ "systems": "systems_2" }, "locked": { - "lastModified": 1766849711, - "narHash": "sha256-gtLBwhgjERca1UCzGkFplD5epIVRiNkePHVVtyFr73g=", + "lastModified": 1769049374, + "narHash": "sha256-h0Os2qqNyycDY1FyZgtbn28VF1ySP74/n0f+LDd8j+w=", "owner": "nix-community", "repo": "nixvim", - "rev": "cae79c48e93bd61e478dfc12456bf68b1ce66074", + "rev": "b8f76bf5751835647538ef8784e4e6ee8deb8f95", "type": "github" }, "original": { @@ -164,11 +164,11 @@ ] }, "locked": { - "lastModified": 1761730856, - "narHash": "sha256-t1i5p/vSWwueZSC0Z2BImxx3BjoUDNKyC2mk24krcMY=", + "lastModified": 1768249818, + "narHash": "sha256-ANfn5OqIxq3HONPIXZ6zuI5sLzX1sS+2qcf/Pa0kQEc=", "owner": "NuschtOS", "repo": "search", - "rev": "e29de6db0cb3182e9aee75a3b1fd1919d995d85b", + "rev": "b6f77b88e9009bfde28e2130e218e5123dc66796", "type": "github" }, "original": {