mirror of
				https://github.com/NotAShelf/nvf.git
				synced 2025-10-31 19:12:38 +00:00 
			
		
		
		
	Merge pull request #604 from nezia1/add-nixd
	
		
			
	
		
	
	
		
	
		
			Some checks failed
		
		
	
	
		
			
				
	
				Set up binary cache / cachix (default) (push) Waiting to run
				
			
		
			
				
	
				Set up binary cache / cachix (maximal) (push) Waiting to run
				
			
		
			
				
	
				Set up binary cache / cachix (nix) (push) Waiting to run
				
			
		
			
				
	
				Validate flake & check formatting / Validate Flake (push) Waiting to run
				
			
		
			
				
	
				Validate flake & check formatting / Formatting via Alejandra (push) Waiting to run
				
			
		
			
				
	
				Build and deploy documentation / Check latest commit (push) Waiting to run
				
			
		
			
				
	
				Build and deploy documentation / publish (push) Blocked by required conditions
				
			
		
			
				
	
				Check for typos in the source tree / check-typos (push) Waiting to run
				
			
		
			
				
	
				Validate flake & check documentation / Validate Flake Documentation (push) Has been cancelled
				
			
		
			
				
	
				Validate flake & check documentation / Validate hyperlinks in documentation sources (push) Has been cancelled
				
			
		
		
	
	
		
	
		
			Some checks failed
		
		
	
	Set up binary cache / cachix (default) (push) Waiting to run
				
			Set up binary cache / cachix (maximal) (push) Waiting to run
				
			Set up binary cache / cachix (nix) (push) Waiting to run
				
			Validate flake & check formatting / Validate Flake (push) Waiting to run
				
			Validate flake & check formatting / Formatting via Alejandra (push) Waiting to run
				
			Build and deploy documentation / Check latest commit (push) Waiting to run
				
			Build and deploy documentation / publish (push) Blocked by required conditions
				
			Check for typos in the source tree / check-typos (push) Waiting to run
				
			Validate flake & check documentation / Validate Flake Documentation (push) Has been cancelled
				
			Validate flake & check documentation / Validate hyperlinks in documentation sources (push) Has been cancelled
				
			languages/nix: add nixd
This commit is contained in:
		
				commit
				
					
						ff31e0fe25
					
				
			
		
					 2 changed files with 38 additions and 0 deletions
				
			
		|  | @ -139,3 +139,7 @@ | |||
| 
 | ||||
| - Add `vim.languages.zig.dap` support through pkgs.lldb dap adapter. Code | ||||
|   Inspiration from `vim.languages.clang.dap` implementation. | ||||
| 
 | ||||
| [nezia1](https://github.com/nezia1) | ||||
| 
 | ||||
| - Add support for [nixd](https://github.com/nix-community/nixd) language server. | ||||
|  |  | |||
|  | @ -59,6 +59,40 @@ | |||
|         } | ||||
|       ''; | ||||
|     }; | ||||
| 
 | ||||
|     nixd = { | ||||
|       package = pkgs.nixd; | ||||
|       internalFormatter = true; | ||||
|       lspConfig = '' | ||||
|         lspconfig.nixd.setup{ | ||||
|           capabilities = capabilities, | ||||
|         ${ | ||||
|           if cfg.format.enable | ||||
|           then useFormat | ||||
|           else noFormat | ||||
|         }, | ||||
|           cmd = ${packageToCmd cfg.lsp.package "nixd"}, | ||||
|         ${optionalString cfg.format.enable '' | ||||
|           settings = { | ||||
|             nixd = { | ||||
|           ${optionalString (cfg.format.type == "alejandra") | ||||
|             '' | ||||
|               formatting = { | ||||
|                 command = {"${cfg.format.package}/bin/alejandra", "--quiet"}, | ||||
|               }, | ||||
|             ''} | ||||
|           ${optionalString (cfg.format.type == "nixfmt") | ||||
|             '' | ||||
|               formatting = { | ||||
|                 command = {"${cfg.format.package}/bin/nixfmt"}, | ||||
|               }, | ||||
|             ''} | ||||
|             }, | ||||
|           }, | ||||
|         ''} | ||||
|         } | ||||
|       ''; | ||||
|     }; | ||||
|   }; | ||||
| 
 | ||||
|   defaultFormat = "alejandra"; | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 GitHub
					GitHub