Skip to content

Commit 167e6ce

Browse files
committed
support running solargraph via bundle
1 parent cb8c466 commit 167e6ce

2 files changed

Lines changed: 6 additions & 3 deletions

File tree

ale_linters/ruby/solargraph.vim

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,10 @@ call ale#Set('ruby_solargraph_executable', 'solargraph')
88
call ale#Set('ruby_solargraph_options', {})
99

1010
function! ale_linters#ruby#solargraph#GetCommand(buffer) abort
11-
return '%e' . ale#Pad('stdio')
11+
let l:executable = ale#Var(a:buffer, 'ruby_solargraph_executable')
12+
13+
return ale#ruby#EscapeExecutable(l:executable, 'solargraph')
14+
\ . ale#Pad('stdio')
1215
endfunction
1316

1417
call ale#linter#Define('ruby', {

doc/ale-ruby.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -227,8 +227,8 @@ g:ale_ruby_solargraph_executable
227227
Type: |String|
228228
Default: `'solargraph'`
229229

230-
Override the invoked solargraph binary. This is useful for running solargraph
231-
from binstubs or a bundle.
230+
Override the invoked solargraph binary. Set this to `'bundle'` to invoke
231+
`'bundle` `exec` solargraph'.
232232

233233

234234
===============================================================================

0 commit comments

Comments
 (0)