Merge pull request #1883 from hsanson/add-solargraph-yml-to-root-path-search

Add solargraph.yml file as root path search file.
This commit is contained in:
w0rp 2018-09-06 20:34:34 +01:00 committed by GitHub
commit e0fe97e0a8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 8 additions and 1 deletions

View File

@ -29,7 +29,7 @@ function! ale#ruby#FindProjectRoot(buffer) abort
return l:dir
endif
for l:name in ['Rakefile', 'Gemfile']
for l:name in ['.solargraph.yml', 'Rakefile', 'Gemfile']
let l:dir = fnamemodify(
\ ale#path#FindNearestFile(a:buffer, l:name),
\ ':h'

View File

@ -27,3 +27,10 @@ Execute(should set solargraph for ruby app2):
AssertLSPOptions {}
AssertLSPProject ale#path#Simplify(g:dir . 'command_callback/../ruby_fixtures/valid_ruby_app2')
AssertLSPAddress '127.0.0.1:7658'
Execute(should set solargraph for ruby app3):
call ale#test#SetFilename('../ruby_fixtures/valid_ruby_app3/lib/file.rb')
AssertLSPLanguage 'ruby'
AssertLSPOptions {}
AssertLSPProject ale#path#Simplify(g:dir . 'command_callback/../ruby_fixtures/valid_ruby_app3')
AssertLSPAddress '127.0.0.1:7658'