mirror of
https://github.com/neovim/neovim.git
synced 2025-09-30 15:08:35 +00:00
vim_getenv: $VIMRUNTIME fallback: ../share/nvim/runtime (#6223)
Do this on all systems, so that portable builds work everywhere. This allows us to ship archives with this folder structure: bin/nvim share/nvim/runtime then ./bin/nvim works without the user needing to explicitly set VIMRUNTIME.
This commit is contained in:
@@ -615,8 +615,7 @@ char *vim_getenv(const char *name)
|
||||
vim_path = (char *)p_hf;
|
||||
}
|
||||
|
||||
#ifdef WIN32
|
||||
// Find runtime path relative to the nvim binary i.e. ../share/runtime
|
||||
// Find runtime path relative to the nvim binary: ../share/nvim/runtime
|
||||
if (vim_path == NULL) {
|
||||
char exe_name[MAXPATHL];
|
||||
size_t exe_name_len = MAXPATHL;
|
||||
@@ -633,7 +632,6 @@ char *vim_getenv(const char *name)
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
if (vim_path != NULL) {
|
||||
// remove the file name
|
||||
|
Reference in New Issue
Block a user