summaryrefslogtreecommitdiff
path: root/ale_linters/python/jedils.vim
diff options
context:
space:
mode:
Diffstat (limited to 'ale_linters/python/jedils.vim')
-rw-r--r--ale_linters/python/jedils.vim8
1 files changed, 6 insertions, 2 deletions
diff --git a/ale_linters/python/jedils.vim b/ale_linters/python/jedils.vim
index eae5fb07..d3e15bf2 100644
--- a/ale_linters/python/jedils.vim
+++ b/ale_linters/python/jedils.vim
@@ -16,12 +16,16 @@ endfunction
function! ale_linters#python#jedils#GetCommand(buffer) abort
let l:executable = ale_linters#python#jedils#GetExecutable(a:buffer)
-
let l:exec_args = l:executable =~? 'pipenv$'
\ ? ' run jedi-language-server'
\ : ''
+ let l:env_string = ''
+
+ if ale#Var(a:buffer, 'python_auto_virtualenv')
+ let l:env_string = ale#python#AutoVirtualenvEnvString(a:buffer)
+ endif
- return ale#Escape(l:executable) . l:exec_args
+ return l:env_string . ale#Escape(l:executable) . l:exec_args
endfunction
call ale#linter#Define('python', {