diff options
Diffstat (limited to 'ale_linters/python/refurb.vim')
-rw-r--r-- | ale_linters/python/refurb.vim | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/ale_linters/python/refurb.vim b/ale_linters/python/refurb.vim index 1ae77b77..7f92948a 100644 --- a/ale_linters/python/refurb.vim +++ b/ale_linters/python/refurb.vim @@ -7,6 +7,7 @@ call ale#Set('python_refurb_use_global', get(g:, 'ale_use_global_executables', 0 call ale#Set('python_refurb_change_directory', 1) call ale#Set('python_refurb_auto_pipenv', 0) call ale#Set('python_refurb_auto_poetry', 0) +call ale#Set('python_refurb_auto_uv', 0) function! ale_linters#python#refurb#GetExecutable(buffer) abort if (ale#Var(a:buffer, 'python_auto_pipenv') || ale#Var(a:buffer, 'python_refurb_auto_pipenv')) @@ -19,6 +20,11 @@ function! ale_linters#python#refurb#GetExecutable(buffer) abort return 'poetry' endif + if (ale#Var(a:buffer, 'python_auto_uv') || ale#Var(a:buffer, 'python_refurb_auto_uv')) + \ && ale#python#UvPresent(a:buffer) + return 'uv' + endif + return ale#python#FindExecutable(a:buffer, 'python_refurb', ['refurb']) endfunction @@ -35,7 +41,7 @@ endfunction function! ale_linters#python#refurb#GetCommand(buffer) abort let l:executable = ale_linters#python#refurb#GetExecutable(a:buffer) - let l:exec_args = l:executable =~? 'pipenv\|poetry$' + let l:exec_args = l:executable =~? 'pipenv\|poetry\|uv$' \ ? ' run refurb' \ : '' |