Open kurko opened 5 years ago
I tried
if filereadable(".todo.reek")
g:ale_ruby_reek_executable = 'reek_with_custom_todo_file'
endif
Got this:
Pattern not found: ale_ruby_reek_executable = 'reek_with_custom_todo_file'
Weird, given g:ale_ruby_reek_executable
is described in the docs...
g:ale_ruby_reek_executable = 'reek_with_custom_todo_file'
needs to be let g:ale_ruby_reek_executable = 'reek_with_custom_todo_file'
. Every line of Vim script needs to be a command.
@w0rp while we're at it... do you think it's productive/scalable to have custom variables for each and every linter/fixer in the universe? Any reason not to have an open string which people can populate with whatever?
Example: g:ale_ruby_reek_executable = 'reek $* -C .todo.reek'
, then replace $*
with whatever arguments are passed in (e.g files). I bet the code is doing some magic and can't support that?
That'd make the plugin automatically configurable and you wouldn't have to spend so much time maintaining it.
Not every linter should be configurable with options. Some require very specific arguments, or no arguments to work. The options have to be set in different places for different commands. The executable path could contain spaces. I have thought about all of this longer than you have.
I'll reopen this. Someone should add an _options
variable for this.
We use
reek -c .todo.reek
. There's no way to specify that-c
option with Ale. Looking at the options in https://github.com/w0rp/ale/blob/master/doc/ale-ruby.txt, it's confirmed that there's no way to do that.The following doesn't work.