mirror of
				https://github.com/NotAShelf/nvf.git
				synced 2025-10-31 02:52:37 +00:00 
			
		
		
		
	Merge branch 'main' into otter-update
This commit is contained in:
		
				commit
				
					
						f1ac8512de
					
				
			
		
					 11 changed files with 26 additions and 16 deletions
				
			
		|  | @ -463,3 +463,6 @@ | ||||||
|   leverage the pattern introduced in commit [fc8206e7a61d ("flake: utilize |   leverage the pattern introduced in commit [fc8206e7a61d ("flake: utilize | ||||||
|   nix-systems for overridable flake systems")]( |   nix-systems for overridable flake systems")]( | ||||||
|   https://github.com/NotAShelf/nvf/commit/fc8206e7a61d7eb02006f9010e62ebdb3336d0d2). |   https://github.com/NotAShelf/nvf/commit/fc8206e7a61d7eb02006f9010e62ebdb3336d0d2). | ||||||
|  | 
 | ||||||
|  | [soliprem](https://github.com/soliprem): | ||||||
|  | - fix broken `neorg` grammars | ||||||
|  |  | ||||||
|  | @ -15,8 +15,7 @@ | ||||||
|     pname = "avante-nvim-lib"; |     pname = "avante-nvim-lib"; | ||||||
|     inherit version src; |     inherit version src; | ||||||
| 
 | 
 | ||||||
|     useFetchCargoVendor = true; |     cargoHash = "sha256-8mBpzndz34RrmhJYezd4hLrJyhVL4S4IHK3plaue1k8="; | ||||||
|     cargoHash = "sha256-pmnMoNdaIR0i+4kwW3cf01vDQo39QakTCEG9AXA86ck="; |  | ||||||
| 
 | 
 | ||||||
|     nativeBuildInputs = [ |     nativeBuildInputs = [ | ||||||
|       pkg-config |       pkg-config | ||||||
|  |  | ||||||
|  | @ -88,7 +88,7 @@ | ||||||
| in { | in { | ||||||
|   options.vim = { |   options.vim = { | ||||||
|     diagnostics = { |     diagnostics = { | ||||||
|       enable = mkEnableOption "diagostics module for Neovim"; |       enable = mkEnableOption "diagnostics module for Neovim"; | ||||||
|       config = mkOption { |       config = mkOption { | ||||||
|         type = diagnosticsSubmodule; |         type = diagnosticsSubmodule; | ||||||
|         default = {}; |         default = {}; | ||||||
|  |  | ||||||
|  | @ -35,7 +35,7 @@ in { | ||||||
| 
 | 
 | ||||||
|     (mkIf cfg.treesitter.enable { |     (mkIf cfg.treesitter.enable { | ||||||
|       vim.treesitter.enable = true; |       vim.treesitter.enable = true; | ||||||
|       vim.treesitter.grammars = [cfg.treesitter.norgPackage]; |       vim.treesitter.grammars = [cfg.treesitter.norgPackage cfg.treesitter.norgMetaPackage]; | ||||||
|     }) |     }) | ||||||
|   ]); |   ]); | ||||||
| } | } | ||||||
|  |  | ||||||
|  | @ -4,9 +4,9 @@ | ||||||
|   pkgs, |   pkgs, | ||||||
|   ... |   ... | ||||||
| }: let | }: let | ||||||
|   inherit (lib.options) mkEnableOption mkOption; |   inherit (lib.options) mkPackageOption mkEnableOption mkOption; | ||||||
|   inherit (lib.types) submodule listOf str; |   inherit (lib.types) submodule listOf str; | ||||||
|   inherit (lib.nvim.types) mkGrammarOption mkPluginSetupOption; |   inherit (lib.nvim.types) mkPluginSetupOption; | ||||||
| in { | in { | ||||||
|   options.vim.notes.neorg = { |   options.vim.notes.neorg = { | ||||||
|     enable = mkEnableOption '' |     enable = mkEnableOption '' | ||||||
|  | @ -44,7 +44,12 @@ in { | ||||||
| 
 | 
 | ||||||
|     treesitter = { |     treesitter = { | ||||||
|       enable = mkEnableOption "Neorg treesitter" // {default = config.vim.languages.enableTreesitter;}; |       enable = mkEnableOption "Neorg treesitter" // {default = config.vim.languages.enableTreesitter;}; | ||||||
|       norgPackage = mkGrammarOption pkgs "norg"; |       norgPackage = mkPackageOption pkgs ["norg-meta treesitter"] { | ||||||
|  |         default = ["tree-sitter-grammars" "tree-sitter-norg"]; | ||||||
|  |       }; | ||||||
|  |       norgMetaPackage = mkPackageOption pkgs ["norg-meta treesitter"] { | ||||||
|  |         default = ["tree-sitter-grammars" "tree-sitter-norg-meta"]; | ||||||
|  |       }; | ||||||
|     }; |     }; | ||||||
|   }; |   }; | ||||||
| } | } | ||||||
|  |  | ||||||
|  | @ -65,6 +65,9 @@ in { | ||||||
|         ${optionalString ( |         ${optionalString ( | ||||||
|           cfg.customSnippets.snipmate != {} |           cfg.customSnippets.snipmate != {} | ||||||
|         ) "require('luasnip.loaders.from_snipmate').lazy_load()"} |         ) "require('luasnip.loaders.from_snipmate').lazy_load()"} | ||||||
|  |         ${optionalString ( | ||||||
|  |           config.vim.autocomplete.nvim-cmp.enable || config.vim.autocomplete.blink-cmp.friendly-snippets.enable | ||||||
|  |         ) "require('luasnip.loaders.from_vscode').lazy_load()"} | ||||||
|       ''; |       ''; | ||||||
|     }; |     }; | ||||||
|   }; |   }; | ||||||
|  |  | ||||||
|  | @ -246,10 +246,10 @@ in { | ||||||
|         transparent = { |         transparent = { | ||||||
|           enabled = ${boolToString transparent}, |           enabled = ${boolToString transparent}, | ||||||
|         }, |         }, | ||||||
|         ${optionalString (!isNull palette) ''palette = "${palette}",''} |         ${optionalString (palette != null) ''palette = "${palette}",''} | ||||||
|         ${optionalString (!isNull variant) ''variant = "${variant}",''} |         ${optionalString (variant != null) ''variant = "${variant}",''} | ||||||
|       } |       } | ||||||
|       ${optionalString (!isNull background) ''vim.opt.background = "${background}"''} |       ${optionalString (background != null) ''vim.opt.background = "${background}"''} | ||||||
|       vim.cmd.colorscheme "solarized" |       vim.cmd.colorscheme "solarized" | ||||||
|     ''; |     ''; | ||||||
|     styles = let |     styles = let | ||||||
|  |  | ||||||
|  | @ -106,7 +106,7 @@ in { | ||||||
|           -- Disable slow treesitter highlight for large files |           -- Disable slow treesitter highlight for large files | ||||||
|           function(lang, buf) |           function(lang, buf) | ||||||
|             local max_filesize = 1000 * 1024 -- 1MB |             local max_filesize = 1000 * 1024 -- 1MB | ||||||
|             local ok, stats = pcall(vim.loop.fs_stat, vim.api.nvim_buf_get_name(buf)) |             local ok, stats = pcall(vim.uv.fs_stat, vim.api.nvim_buf_get_name(buf)) | ||||||
|             if ok and stats and stats.size > max_filesize then |             if ok and stats and stats.size > max_filesize then | ||||||
|                 return true |                 return true | ||||||
|             end |             end | ||||||
|  |  | ||||||
|  | @ -10,7 +10,7 @@ | ||||||
|   inherit (lib.nvim.dag) entryAnywhere; |   inherit (lib.nvim.dag) entryAnywhere; | ||||||
| 
 | 
 | ||||||
|   cfg = config.vim.binds.whichKey; |   cfg = config.vim.binds.whichKey; | ||||||
|   register = mapAttrsToList (n: v: lib.lists.optional (! isNull v) (mkLuaInline "{ '${n}', desc = '${v}' }")) cfg.register; |   register = mapAttrsToList (n: v: lib.lists.optional (v != null) (mkLuaInline "{ '${n}', desc = '${v}' }")) cfg.register; | ||||||
| in { | in { | ||||||
|   config = mkIf cfg.enable { |   config = mkIf cfg.enable { | ||||||
|     vim = { |     vim = { | ||||||
|  |  | ||||||
|  | @ -39,7 +39,7 @@ in { | ||||||
|           type = luaInline; |           type = luaInline; | ||||||
|           default = mkLuaInline '' |           default = mkLuaInline '' | ||||||
|             function() |             function() | ||||||
|               return vim.loop.cwd() |               return vim.uv.cwd() | ||||||
|             end |             end | ||||||
|           ''; |           ''; | ||||||
|           description = '' |           description = '' | ||||||
|  |  | ||||||
|  | @ -35,9 +35,9 @@ | ||||||
|       }, |       }, | ||||||
|       "branch": "main", |       "branch": "main", | ||||||
|       "submodules": false, |       "submodules": false, | ||||||
|       "revision": "2dd4c040880b271861369b361489a2d418d42648", |       "revision": "154e5f578f8925135a9dd23764d4c33a10c7ae36", | ||||||
|       "url": "https://github.com/yetone/avante.nvim/archive/2dd4c040880b271861369b361489a2d418d42648.tar.gz", |       "url": "https://github.com/yetone/avante.nvim/archive/154e5f578f8925135a9dd23764d4c33a10c7ae36.tar.gz", | ||||||
|       "hash": "01j92m0qhd5g6m92rp0qnr4vqqgfrhbx91jbrrcjj1npizynxjm1" |       "hash": "0hx5ccfkn7ljnprzl6qwvb9ba86zrkqysh18zvnaq360g95d4ca1" | ||||||
|     }, |     }, | ||||||
|     "base16": { |     "base16": { | ||||||
|       "type": "Git", |       "type": "Git", | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 GitHub
					GitHub