From the doc:
flycheck-disabled-checkers is a variable defined in ‘flycheck.el’.
Its value is nil
Automatically becomes buffer-local when set.
This variable is safe as a file local variable if its value
satisfies the predicate ‘flycheck-symbol-list-p’.
You can customize this variable.
This variable is a buffer-local variable.
When you call
add-to-list on it, it was set as locally. Check out the example call from ielm below.
One possible option is to customize it using the
customize interface to let it set globally for you.
- In fact you can set it in
.dir-locals.el. This will set the variable for a lot of files ("directory local" variable is still file local, I might add). E.g. I tried setting the following (see below), and checkers are all disabled for every python file in the entire projectile dir.
;;; Directory Local Variables
;;; For more information see (info "(emacs) Directory Variables")
((python-mode . ((flycheck-disabled-checkers . (python-mypy python-flake8 python-pylint)))))
- How to customize & set it globally once and for all
C-h v (or
SPC h d v, spacemacs only) and select
customize in the sentence "You can customize this variable.".
- In the interface, click
INS to insert a value
python-mypy as you wish
State and choose what you want
- You can try out in the current session only
- You can persist the customization for future use also
- OR you can revert if you mess up