Return only the unescaped executables from executable callbacks

This commit is contained in:
w0rp
2018-09-14 13:24:59 +01:00
parent 9e09b7ca35
commit 5c86ffd321
7 changed files with 20 additions and 43 deletions

View File

@@ -2,9 +2,9 @@
" Description: RuboCop, a code style analyzer for Ruby files
function! ale_linters#ruby#rubocop#GetCommand(buffer) abort
let l:executable = ale#handlers#rubocop#GetExecutable(a:buffer)
let l:executable = ale#Var(a:buffer, 'ruby_rubocop_executable')
return l:executable
return ale#handlers#ruby#EscapeExecutable(l:executable, 'rubocop')
\ . ' --format json --force-exclusion '
\ . ale#Var(a:buffer, 'ruby_rubocop_options')
\ . ' --stdin ' . ale#Escape(expand('#' . a:buffer . ':p'))