summaryrefslogtreecommitdiff
path: root/ale_linters/ruby
diff options
context:
space:
mode:
authorw0rp <devw0rp@gmail.com>2019-02-22 18:05:04 +0000
committerw0rp <devw0rp@gmail.com>2019-02-22 18:05:04 +0000
commit883978ece93bd19250d6d7e8b9659b48f23522e2 (patch)
tree8ac9417b7c980906295745cc5ea709b91a789390 /ale_linters/ruby
parentf53b25d2567a2f7495dab444680596f48de427d1 (diff)
downloadale-883978ece93bd19250d6d7e8b9659b48f23522e2.zip
#2132 - Replace all uses of foo_callback with foo
Diffstat (limited to 'ale_linters/ruby')
-rw-r--r--ale_linters/ruby/brakeman.vim4
-rw-r--r--ale_linters/ruby/rails_best_practices.vim4
-rw-r--r--ale_linters/ruby/reek.vim2
-rw-r--r--ale_linters/ruby/rubocop.vim4
-rw-r--r--ale_linters/ruby/ruby.vim2
-rw-r--r--ale_linters/ruby/solargraph.vim8
-rw-r--r--ale_linters/ruby/standardrb.vim4
7 files changed, 14 insertions, 14 deletions
diff --git a/ale_linters/ruby/brakeman.vim b/ale_linters/ruby/brakeman.vim
index 122e0b5b..a8088080 100644
--- a/ale_linters/ruby/brakeman.vim
+++ b/ale_linters/ruby/brakeman.vim
@@ -44,8 +44,8 @@ endfunction
call ale#linter#Define('ruby', {
\ 'name': 'brakeman',
-\ 'executable_callback': ale#VarFunc('ruby_brakeman_executable'),
-\ 'command_callback': 'ale_linters#ruby#brakeman#GetCommand',
+\ 'executable': {b -> ale#Var(b, 'ruby_brakeman_executable')},
+\ 'command': function('ale_linters#ruby#brakeman#GetCommand'),
\ 'callback': 'ale_linters#ruby#brakeman#Handle',
\ 'lint_file': 1,
\})
diff --git a/ale_linters/ruby/rails_best_practices.vim b/ale_linters/ruby/rails_best_practices.vim
index 20cadca8..680cc364 100644
--- a/ale_linters/ruby/rails_best_practices.vim
+++ b/ale_linters/ruby/rails_best_practices.vim
@@ -42,8 +42,8 @@ endfunction
call ale#linter#Define('ruby', {
\ 'name': 'rails_best_practices',
-\ 'executable_callback': ale#VarFunc('ruby_rails_best_practices_executable'),
-\ 'command_callback': 'ale_linters#ruby#rails_best_practices#GetCommand',
+\ 'executable': {b -> ale#Var(b, 'ruby_rails_best_practices_executable')},
+\ 'command': function('ale_linters#ruby#rails_best_practices#GetCommand'),
\ 'callback': 'ale_linters#ruby#rails_best_practices#Handle',
\ 'lint_file': 1,
\})
diff --git a/ale_linters/ruby/reek.vim b/ale_linters/ruby/reek.vim
index 53363d31..26f6e36c 100644
--- a/ale_linters/ruby/reek.vim
+++ b/ale_linters/ruby/reek.vim
@@ -69,7 +69,7 @@ endfunction
call ale#linter#Define('ruby', {
\ 'name': 'reek',
-\ 'executable_callback': ale#VarFunc('ruby_reek_executable'),
+\ 'executable': {b -> ale#Var(b, 'ruby_reek_executable')},
\ 'command_chain': [
\ {'callback': 'ale_linters#ruby#reek#VersionCheck'},
\ {'callback': 'ale_linters#ruby#reek#GetCommand'},
diff --git a/ale_linters/ruby/rubocop.vim b/ale_linters/ruby/rubocop.vim
index 790ca82c..8b9e9c84 100644
--- a/ale_linters/ruby/rubocop.vim
+++ b/ale_linters/ruby/rubocop.vim
@@ -25,7 +25,7 @@ endfunction
call ale#linter#Define('ruby', {
\ 'name': 'rubocop',
-\ 'executable_callback': ale#VarFunc('ruby_rubocop_executable'),
-\ 'command_callback': 'ale_linters#ruby#rubocop#GetCommand',
+\ 'executable': {b -> ale#Var(b, 'ruby_rubocop_executable')},
+\ 'command': function('ale_linters#ruby#rubocop#GetCommand'),
\ 'callback': 'ale#ruby#HandleRubocopOutput',
\})
diff --git a/ale_linters/ruby/ruby.vim b/ale_linters/ruby/ruby.vim
index 2bc4ec4b..2dc55eb0 100644
--- a/ale_linters/ruby/ruby.vim
+++ b/ale_linters/ruby/ruby.vim
@@ -5,7 +5,7 @@ call ale#Set('ruby_ruby_executable', 'ruby')
call ale#linter#Define('ruby', {
\ 'name': 'ruby',
-\ 'executable_callback': ale#VarFunc('ruby_ruby_executable'),
+\ 'executable': {b -> ale#Var(b, 'ruby_ruby_executable')},
\ 'command': '%e -w -c -T1 %t',
\ 'output_stream': 'stderr',
\ 'callback': 'ale#handlers#ruby#HandleSyntaxErrors',
diff --git a/ale_linters/ruby/solargraph.vim b/ale_linters/ruby/solargraph.vim
index 5ff0a759..bf54a55c 100644
--- a/ale_linters/ruby/solargraph.vim
+++ b/ale_linters/ruby/solargraph.vim
@@ -15,8 +15,8 @@ call ale#linter#Define('ruby', {
\ 'name': 'solargraph',
\ 'lsp': 'stdio',
\ 'language': 'ruby',
-\ 'executable_callback': ale#VarFunc('ruby_solargraph_executable'),
-\ 'command_callback': 'ale_linters#ruby#solargraph#GetCommand',
-\ 'project_root_callback': 'ale#ruby#FindProjectRoot',
-\ 'initialization_options_callback': ale#VarFunc('ruby_solargraph_options'),
+\ 'executable': {b -> ale#Var(b, 'ruby_solargraph_executable')},
+\ 'command': function('ale_linters#ruby#solargraph#GetCommand'),
+\ 'project_root': function('ale#ruby#FindProjectRoot'),
+\ 'initialization_options': {b -> ale#Var(b, 'ruby_solargraph_options')},
\})
diff --git a/ale_linters/ruby/standardrb.vim b/ale_linters/ruby/standardrb.vim
index 95e10934..f075a7d5 100644
--- a/ale_linters/ruby/standardrb.vim
+++ b/ale_linters/ruby/standardrb.vim
@@ -17,7 +17,7 @@ endfunction
" standardrb is based on RuboCop so the callback is the same
call ale#linter#Define('ruby', {
\ 'name': 'standardrb',
-\ 'executable_callback': ale#VarFunc('ruby_standardrb_executable'),
-\ 'command_callback': 'ale_linters#ruby#standardrb#GetCommand',
+\ 'executable': {b -> ale#Var(b, 'ruby_standardrb_executable')},
+\ 'command': function('ale_linters#ruby#standardrb#GetCommand'),
\ 'callback': 'ale#ruby#HandleRubocopOutput',
\})