mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
test/old: detect user modules for python,ruby
Set the environment variables before changing $HOME
so that python,ruby can find user modules not in $HOME.
Reference:
- 7be7ec98a2
- https://github.com/neovim/neovim/issues/10270#issuecomment-531516948
This commit is contained in:
parent
c65dd2d114
commit
36a1670151
@ -31,12 +31,6 @@ let &packpath = &rtp
|
||||
" Avoid storing shell history.
|
||||
let $HISTFILE = ""
|
||||
|
||||
" Make sure $HOME does not get read or written.
|
||||
let $HOME = expand(getcwd() . '/XfakeHOME')
|
||||
if !isdirectory($HOME)
|
||||
call mkdir($HOME)
|
||||
endif
|
||||
|
||||
" Use default shell on Windows to avoid segfault, caused by TUI
|
||||
if has('win32')
|
||||
let $SHELL = ''
|
||||
@ -45,3 +39,15 @@ if has('win32')
|
||||
set shellcmdflag=/s/c shellxquote=\" shellredir=>%s\ 2>&1
|
||||
let &shellpipe = &shellredir
|
||||
endif
|
||||
|
||||
" Detect user modules for language providers
|
||||
let $PYTHONUSERBASE = $HOME . '/.local'
|
||||
if executable('gem')
|
||||
let $GEM_PATH = system('gem env gempath')
|
||||
endif
|
||||
|
||||
" Make sure $HOME does not get read or written.
|
||||
let $HOME = expand(getcwd() . '/XfakeHOME')
|
||||
if !isdirectory($HOME)
|
||||
call mkdir($HOME)
|
||||
endif
|
||||
|
Loading…
Reference in New Issue
Block a user