2021-06-11 22:55:32 +02:00
|
|
|
""" ALE configuration
|
|
|
|
|
2021-06-15 16:26:37 +02:00
|
|
|
let g:ale_completion_enabled = 0
|
2021-06-11 22:55:32 +02:00
|
|
|
let g:ale_sign_error = '->'
|
|
|
|
let g:ale_sign_warning = '~>'
|
|
|
|
" let g:ale_sign_error = '✘'
|
|
|
|
" let g:ale_sign_warning = '⚠'
|
|
|
|
|
|
|
|
let g:ale_elixir_elixir_ls_release = '/usr/lib/elixir-ls/'
|
2021-10-08 10:12:32 +02:00
|
|
|
let g:ale_java_javalsp_executable = '/usr/bin/java-language-server'
|
2021-06-11 22:55:32 +02:00
|
|
|
|
|
|
|
let g:ale_linters = {
|
|
|
|
\ 'javascript': ['eslint'],
|
2021-07-19 21:02:22 +02:00
|
|
|
\ 'javascriptreact': ['eslint'],
|
2021-06-11 22:55:32 +02:00
|
|
|
\ 'typescript': ['tsserver', 'tslint'],
|
2021-07-19 21:02:22 +02:00
|
|
|
\ 'typescriptreact': ['tsserver', 'tslint'],
|
2021-06-11 22:55:32 +02:00
|
|
|
\ 'python': ['pyls', 'pylint'],
|
|
|
|
\ 'rust': ['rls'],
|
|
|
|
\ 'elixir': ['elixir-ls'],
|
|
|
|
\ 'go': ['gopls'],
|
|
|
|
\ 'json': ['jsonlint'],
|
|
|
|
\ 'dockerfile': ['hadolint'],
|
|
|
|
\ 'vala': ['vala-language-server'],
|
|
|
|
\ 'scss': ['eslint'],
|
|
|
|
\ 'elm': ['elm_ls'],
|
2021-07-19 21:02:22 +02:00
|
|
|
\ 'sql': ['sql-lint'],
|
2021-07-19 21:02:39 +02:00
|
|
|
\ 'promql': ['promql-langserver'],
|
2021-10-08 10:12:32 +02:00
|
|
|
\ 'java': ['javalsp'],
|
2022-02-21 18:45:05 +01:00
|
|
|
\ 'ps1': ['powershell'],
|
2021-06-11 22:55:32 +02:00
|
|
|
\}
|
|
|
|
|
|
|
|
let g:ale_fixers = {
|
|
|
|
\ 'javascript': ['prettier'],
|
|
|
|
\ 'typescript': ['prettier'],
|
2021-07-19 21:02:22 +02:00
|
|
|
\ 'javascriptreact': ['prettier'],
|
|
|
|
\ 'typescriptreact': ['prettier'],
|
2021-06-11 22:55:32 +02:00
|
|
|
\ 'python': ['black', 'pyls'],
|
|
|
|
\ 'rust': ['rustfmt'],
|
|
|
|
\ 'elixir': ['mix_format'],
|
|
|
|
\ 'graphql': ['prettier'],
|
|
|
|
\ 'perl': ['perltidy'],
|
|
|
|
\ 'go': ['gofmt'],
|
|
|
|
\ 'json': ['prettier'],
|
|
|
|
\ 'vala': ['uncrustify'],
|
|
|
|
\ 'dart': ['dartfmt'],
|
|
|
|
\ 'scss': ['prettier'],
|
|
|
|
\}
|
|
|
|
|
|
|
|
let g:ale_rust_rls_config = {
|
|
|
|
\ 'rust': {
|
|
|
|
\ 'clippy_preference': 'on'
|
|
|
|
\ }
|
|
|
|
\ }
|
|
|
|
|
|
|
|
let g:ale_echo_msg_error_str = 'Err'
|
|
|
|
let g:ale_echo_msg_warning_str = 'Warn'
|
|
|
|
let g:ale_echo_msg_format = '[%linter%] %s [%severity%]'
|
|
|
|
|
|
|
|
let g:ale_go_langserver_executable = 'gopls'
|
|
|
|
" let g:ale_go_revive_executable = '/usr/bin/revive'
|
|
|
|
" let g:ale_go_revive_options = '-config ~/.vim/revive.toml'
|
|
|
|
|
|
|
|
let g:airline#extensions#ale#enabled = 1
|
|
|
|
|
2021-07-19 21:02:22 +02:00
|
|
|
" let g:ale_completion_enabled = 1
|
2021-06-11 22:55:32 +02:00
|
|
|
let g:ale_lint_on_enter = 0
|
|
|
|
let g:ale_lint_on_text_changed = 'never'
|
|
|
|
highlight ALEErrorSign ctermbg=NONE ctermfg=red
|
|
|
|
highlight ALEWarningSign ctermbg=NONE ctermfg=yellow
|
|
|
|
let g:ale_linters_explicit = 1
|
|
|
|
let g:ale_lint_on_save = 1
|
|
|
|
let g:ale_fix_on_save = 1
|
|
|
|
|
2021-07-19 21:02:22 +02:00
|
|
|
" let g:ale_set_balloons = 1
|
|
|
|
let g:ale_hover_to_preview = 1
|
|
|
|
let g:ale_float_preview = 1
|
|
|
|
let g:ale_floating_window_border = ['│', '─', '╭', '╮', '╯', '╰']
|