My Neovim config using nixvim.
Note
The colorscheme in these screenshots is paradise
To start configuring, just add or modify the nix files in ./config
.
If you add a new configuration file, remember to add it to the
config/default.nix
file
Warning
Some of them might be disabled, this is every plugins defined and configured in the repo.
List of plugins
- colorscheme/: Theme configuration. Current one is paradise
- completion/
- avante: Cursor AI at home
- copilot-cmp: Completion support for GitHub copilot
- lspkind: vscode-like pictograms for neovim lsp completion items
- nvim-cmp: Completion plugin for nvim + emoji support
- schemastore.nvim: Schemastore integration
- git/
- lsp/
- snacks
- set of utilities
- snippet/
- luasnip: Snippet engine in lua
- statusline/
- lualine: Status line for neovim
- treesitter/
- treesitter-context: Show code context
- treesitter-textobject: Allow cool text manipulation thanks to TS
- treesitter: Parser generator tool to build a syntax tree of the current buffer
- ui/
- bufferline: VSCode like line for buffers -> replaced by mini.tabline
- dressing: Better vim ui interfaces
- fzf-lua: fzf-lua is my new best friend
- noice: Better nvim UI
- nvim-notify: Notification manager
- smart-splits: Better split managment
- telescope: Best plugin ever ? Nevermind
- utils/
- comment: Quickly toggle comments
- comment-box: Comments utilities
- markview: Yet another markdown previewer for neovim
- mini: Cool neovim utilities, currently using ai, notify, surround, diff, tabline, trailspace, icons, indentscope and pairs
- nvim-colorizer: Preview colors in neovim
- obsidian: Obsidian integration for nvim
- oil: Navigate in your working folder with a buffer
- spectre: Search and replace
- ufo: Folding plugin
- undotree: Undo history visualizer
To test your configuration simply run the following command
nix run .
If you have nix installed, you can directly run my config from anywhere
You can try running mine with:
nix run 'github:elythh/nixvim'
This nixvim
flake will output a derivation that you can easily include
in either home.packages
for home-manager
, or
environment.systemPackages
for NixOS
. Or whatever happens with darwin?
You can add my nixvim
configuration as an input to your NixOS
configuration like:
{
inputs = {
nixvim.url = "github:elythh/nixvim";
};
}
With the input added you can reference it directly.
{ inputs, system, ... }:
{
# NixOS
environment.systemPackages = [ inputs.nixvim.packages.${pkgs.system}.default ];
# home-manager
home.packages = [ inputs.nixvim.packages.${pkgs.system}.default ];
}
The binary built by nixvim
is already named as nvim
so you can call it just
like you normally would.
Another method is to overlay your custom build over neovim
from nixpkgs
.
This method is less straight-forward but allows you to install neovim
like
you normally would. With this method you would just install neovim
in your
configuration (home.packges = with pkgs; [ neovim ]
), but you replace
neovim
in pkgs
with your derivation from nixvim
.
{
pkgs = import inputs.nixpkgs {
overlays = [
(final: prev: {
neovim = inputs.nixvim.packages.${pkgs.system}.default;
})
];
}
}
You can just straight up alias something like nix run 'github:elythh/nixvim'
to nvim
.
If you want to extend this configuration is your own NixOS config, you can do so using nixvimExtend
. See here for more info.
Example for overwriting the theme
{
inputs,
lib,
...
}: let
nixvim' = inputs.nixvim.packages."x86_64-linux".default;
nvim = nixvim'.nixvimExtend {
config.theme = lib.mkForce "jellybeans";
};
in {
home.packages = [
nvim
];
}