Comments (13)
A workaround I'm using at the moment is just to make a symlink where it expects to see the folder:
sudo ln -s /nix/store/7vaavg9j2q0xg6w1wr42hir1vbsh2b90-neovim-0.7.0/share/nvim/runtime /etc/nvim
I'm sure there's a more sensible way to get the hash in the nix store path, but since I'm new to Nix I've just been using file $(which nvim)
to find out where it's located.
from nixvim.
I'll take a look at this, but now that 21.11 is released (and AFAICT it works there), maybe it's not worth patching in the support for older versions. If there's enough demand I'll add something for this though.
from nixvim.
Yeah, mostly opened for continuing tracking on the $VIMRUNTIME
issue that's been following us... I actually suspect it's still present in 21.11 some situations. I've had it crop up since upgrading, but I haven't yet taken the time to make it reproducible, so it might be my imagination.
from nixvim.
I can confirm that I've also been having this issue on NixOS 22.11
from nixvim.
Same here, also having this issue.
from nixvim.
Ah damn it, thought it had gone away! Can you share a basic config @JulienMalka and @Church-? Also, what module are you using to set up nixvim?
from nixvim.
Hey there, I'm using the nixOS module to set up my config, and my config is
{ pkgs, config, ... }:
{
programs = {
nixvim = {
enable = true;
viAlias = true;
vimAlias = true;
options = {
termguicolors = true;
background = "dark";
ignorecase = true;
swapfile = false;
showmatch = true;
hlsearch = true;
wildmode = [ "longest" "list" ];
expandtab = true;
tabstop = 4;
shiftwidth = 4;
};
extraConfigVim = ''
set completeopt=menuone,noinsert,noselect
set shortmess+=c
set whichwrap+=<,>,h,l,[,]
au BufRead,BufNewFile *.md setlocal textwidth=80
au BufRead,BufNewFile *.yaml setlocal textwidth=80 shiftwidth=2 cc=80
au BufRead,BufNewFile *.yml setlocal textwidth=80 shiftwidth=2 cc=80
au BufRead,BufNewFile *.sls setlocal textwidth=80 shiftwidth=2 cc=80
au BufRead,BufNewFile *.sh setlocal textwidth=80 shiftwidth=2 cc=80
au BufRead,BufNewFile *.nix setlocal textwidth=80 shiftwidth=2 cc=80
au BufRead,BufNewFile *.js setlocal textwidth=80 shiftwidth=2 cc=80
au BufRead,BufNewFile *.ts setlocal textwidth=80 shiftwidth=2 cc=80
au BufRead,BufNewFile *.lua setlocal textwidth=80 shiftwidth=2 cc=80
au BufRead,BufNewFile *.py setlocal textwidth=80 shiftwidth=4 cc=88
au BufRead,BufNewFile *.rs setlocal textwidth=80 shiftwidth=4 cc=80
au BufRead,BufNewFile *.c setlocal textwidth=80 shiftwidth=4 cc=80
au BufRead,BufNewFile *.go setlocal textwidth=80 shiftwidth=4 cc=80
au BufWrite *.rs :Autoformat
au BufWrite *.nix :Autoformat
'';
plugins = {
lsp = {
enable = true;
servers = {
rnix-lsp = { enable = true; };
rust-analyzer = { enable = true; };
};
};
};
};
};
}
from nixvim.
Changed name to reflect that this is no longer a 22.05 issue. I also had the same thing pop up on 22.11 on my WSL install: see configuration
from nixvim.
can confirm the same issue with nixpkgs/nixos-unstable. creating the symlink as mentioned by @volkswagenfeature worked for me.
still i have to point nvim to the correct config using nvim -u /etc/nvim/sysinit.lua
from nixvim.
In my case, the runtime issue was fixed with commenting this line: https://github.com/pta2002/nixvim/blob/main/wrappers/nixos.nix#L35
from nixvim.
same here
but non of the tricks here works for me
it is strange that, but I am not so experienced with NixOS, when I added nixvim, the log sayed that ... input 'nixvim/pre-commit-hooks/nixpkgs-stable'
but the documentation stated that nixvim needs an unstable version
NixOS with flakes
{
description = "lump";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
home-manager.url = "github:nix-community/home-manager";
home-manager.inputs.nixpkgs.follows = "nixpkgs";
nixvim.url = github:pta2002/nixvim;
nixvim.inputs.nixpkgs.follows = "nixpkgs";
};
outputs = inputs@{ nixpkgs, home-manager, nixvim, ... }: {
nixosConfigurations = {
qq = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
./configuration.nix
home-manager.nixosModules.home-manager {
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.qq = import ./home.nix;
}
nixvim.nixosModules.nixvim {
programs.nixvim = {
enable = true;
options = {
number = true;
relativenumber = true;
shiftwidth = 4;
tabstop = 4;
};
plugins.oil.enable = true;
plugins.lightline.enable = true;
maps = {
normal."-" = {
action = "<cmd>require('oil').open";
};
};
};
}
];
};
};
};
}
and I also have problem with infinite loop if I trying to call nixvim from ./home.nix
from nixvim.
In my case, the runtime issue was fixed with commenting this line: https://github.com/pta2002/nixvim/blob/main/wrappers/nixos.nix#L35
Setting wrapRc = true;
fixed this issue for me on nixos-unstable. My config worked just fine on nix-darwin and I noticed the darwin wrapper has wrapRc forced to true, so I guess I need true for both
from nixvim.
wrapRc sets VIM which is used as VIMRUNTIME see :h VIMRUNTIME
from nixvim.
Related Issues (20)
- [PLUGIN REQUEST] virt-column.nvim
- [BUG] attribute 'base16-nvim' missing HOT 2
- [BUG] Can't install nixvim, "option ... does not exist" HOT 2
- [BUG] Alpha terminal
- [BUG] Conform plugin does not install enabled formatters
- [PLUGIN REQUEST] indent-o-matic
- [PLUGIN REQUEST] direnv.vim
- [PLUGIN REQUEST] crates.nvim HOT 2
- Running `nix flake show` fails to evaluate on `x86_64-linux` HOT 2
- [BUG] copilot-vim.keymaps do not work properly
- LSP keymaps should use keymap-helpers submodule HOT 2
- [PLUGIN REQUEST] lsp-status.nvim
- [BUG] error: `phpcbf` is now deprecated, use `php-codesniffer` instead which contains both `phpcs` and `phpcbf`. HOT 14
- [PLUGIN REQUEST] vim-sandwich
- [BUG] Treesitter configures custom parser lists incorrectly HOT 4
- plugins/whichkey: Support window and layout fields HOT 1
- [PLUGIN REQUEST] <auto-save fork>
- [BUG] [nvim-cmp] unable to pass a function in sources entryFilter HOT 3
- nord colorscheme not starting on launch due to `colorscheme` not set when `colorschemes.nord.enable = true;` HOT 4
- [PLUGIN REQUEST] cmp_yanky HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from nixvim.