diff options
author | w0rp <devw0rp@gmail.com> | 2017-07-06 22:58:14 +0100 |
---|---|---|
committer | w0rp <devw0rp@gmail.com> | 2017-07-06 22:58:14 +0100 |
commit | 854066e8499344a6461fef8fd0ee4b3f8eaebeeb (patch) | |
tree | 5fa7c99247494296f22ac963471e37307df5be16 /autoload | |
parent | b43413916d0f215fb7a38c53784b3e68360d914a (diff) | |
download | ale-854066e8499344a6461fef8fd0ee4b3f8eaebeeb.zip |
#732 - Use the configuration files when fixing files with rubocop
Diffstat (limited to 'autoload')
-rw-r--r-- | autoload/ale/fixers/rubocop.vim | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/autoload/ale/fixers/rubocop.vim b/autoload/ale/fixers/rubocop.vim index 3f92055f..88dc1c43 100644 --- a/autoload/ale/fixers/rubocop.vim +++ b/autoload/ale/fixers/rubocop.vim @@ -3,8 +3,10 @@ function! ale#fixers#rubocop#GetCommand(buffer) abort let l:exec_args = l:executable =~? 'bundle$' \ ? ' exec rubocop' \ : '' + let l:config = ale#path#FindNearestFile(a:buffer, '.rubocop.yml') return ale#Escape(l:executable) . l:exec_args + \ . (!empty(l:config) ? ' --config ' . ale#Escape(l:config) : '') \ . ' --auto-correct %t' endfunction |