mirror of
https://github.com/amix/vimrc
synced 2025-02-28 14:12:51 +08:00
Merge branch 'master' into jg/pc-test
This commit is contained in:
commit
622c53705b
13
README.md
13
README.md
@ -68,10 +68,6 @@ Just do a git rebase!
|
|||||||
git pull --rebase
|
git pull --rebase
|
||||||
python update_plugins.py # use python3 if python is unavailable
|
python update_plugins.py # use python3 if python is unavailable
|
||||||
|
|
||||||
NOTE: If you get `ModuleNotFoundError: No module named 'requests'`, you must first install the `requests` python module using `pip`, `pip3`, or `easy_install`.
|
|
||||||
|
|
||||||
pip install requests
|
|
||||||
|
|
||||||
## Some screenshots
|
## Some screenshots
|
||||||
|
|
||||||
Colors when editing a Python file:
|
Colors when editing a Python file:
|
||||||
@ -109,7 +105,6 @@ I recommend reading the docs of these plugins to understand them better. Each pl
|
|||||||
* [gist-vim](https://github.com/mattn/gist-vim) Easily create gists from Vim using the `:Gist` command
|
* [gist-vim](https://github.com/mattn/gist-vim) Easily create gists from Vim using the `:Gist` command
|
||||||
* [vim-indent-guides](https://github.com/nathanaelkane/vim-indent-guides) Is a plugin for visually displaying indent levels in Vim
|
* [vim-indent-guides](https://github.com/nathanaelkane/vim-indent-guides) Is a plugin for visually displaying indent levels in Vim
|
||||||
* [editorconfig-vim](https://github.com/editorconfig/editorconfig-vim) EditorConfig helps maintain consistent coding styles for multiple developers working on the same project across various editors and IDEs.
|
* [editorconfig-vim](https://github.com/editorconfig/editorconfig-vim) EditorConfig helps maintain consistent coding styles for multiple developers working on the same project across various editors and IDEs.
|
||||||
* [jedi-vim](https://github.com/davidhalter/jedi-vim) A great Python autocompletion library for VIM.
|
|
||||||
|
|
||||||
|
|
||||||
## Included color schemes
|
## Included color schemes
|
||||||
@ -358,14 +353,6 @@ Open [ctrlp.vim](https://github.com/kien/ctrlp.vim) plugin to quickly find a fil
|
|||||||
nnoremap <leader>v :.GBrowse!<CR>
|
nnoremap <leader>v :.GBrowse!<CR>
|
||||||
xnoremap <leader>v :'<'>GBrowse!<CR>
|
xnoremap <leader>v :'<'>GBrowse!<CR>
|
||||||
|
|
||||||
[jedi-vim](https://github.com/davidhalter/jedi-vim) specific mappings (can be used to browse through Python code quickly):
|
|
||||||
|
|
||||||
let g:jedi#goto_assignments_command = "<leader>a"
|
|
||||||
let g:jedi#usages_command = "<leader>u"
|
|
||||||
let g:jedi#completions_command = "<C-Space>"
|
|
||||||
let g:jedi#rename_command = "<leader>r"
|
|
||||||
|
|
||||||
|
|
||||||
### Spell checking
|
### Spell checking
|
||||||
Pressing `<leader>ss` will toggle spell checking:
|
Pressing `<leader>ss` will toggle spell checking:
|
||||||
|
|
||||||
|
@ -0,0 +1,46 @@
|
|||||||
|
" Author: Horacio Sanson <https://github.com/hsanson>
|
||||||
|
" Description: Support ansible language server https://github.com/ansible/ansible-language-server/
|
||||||
|
|
||||||
|
call ale#Set('ansible_language_server_executable', 'ansible-language-server')
|
||||||
|
call ale#Set('ansible_language_server_config', {})
|
||||||
|
|
||||||
|
function! ale_linters#ansible#ansible_language_server#Executable(buffer) abort
|
||||||
|
return ale#Var(a:buffer, 'ansible_language_server_executable')
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! ale_linters#ansible#ansible_language_server#GetCommand(buffer) abort
|
||||||
|
let l:executable = ale_linters#ansible#ansible_language_server#Executable(a:buffer)
|
||||||
|
|
||||||
|
return ale#Escape(l:executable) . ' --stdio'
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! ale_linters#ansible#ansible_language_server#FindProjectRoot(buffer) abort
|
||||||
|
let l:dir = fnamemodify(
|
||||||
|
\ ale#path#FindNearestFile(a:buffer, 'ansible.cfg'),
|
||||||
|
\ ':h'
|
||||||
|
\)
|
||||||
|
|
||||||
|
if l:dir isnot# '.' && isdirectory(l:dir)
|
||||||
|
return l:dir
|
||||||
|
endif
|
||||||
|
|
||||||
|
let l:dir = fnamemodify(
|
||||||
|
\ ale#path#FindNearestDirectory(a:buffer, '.git'),
|
||||||
|
\ ':h:h'
|
||||||
|
\)
|
||||||
|
|
||||||
|
if l:dir isnot# '.' && isdirectory(l:dir)
|
||||||
|
return l:dir
|
||||||
|
endif
|
||||||
|
|
||||||
|
return ''
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
call ale#linter#Define('ansible', {
|
||||||
|
\ 'name': 'ansible-language-server',
|
||||||
|
\ 'lsp': 'stdio',
|
||||||
|
\ 'executable': function('ale_linters#ansible#ansible_language_server#Executable'),
|
||||||
|
\ 'command': function('ale_linters#ansible#ansible_language_server#GetCommand'),
|
||||||
|
\ 'project_root': function('ale_linters#ansible#ansible_language_server#FindProjectRoot'),
|
||||||
|
\ 'lsp_config': {b -> ale#Var(b, 'ansible_language_server_config')}
|
||||||
|
\})
|
@ -1,5 +1,5 @@
|
|||||||
" Author: kmarc <korondi.mark@gmail.com>
|
" Author: kmarc <korondi.mark@gmail.com>
|
||||||
" Description: This file adds support for using GNU awk with sripts.
|
" Description: This file adds support for using GNU awk with scripts.
|
||||||
|
|
||||||
call ale#Set('awk_gawk_executable', 'gawk')
|
call ale#Set('awk_gawk_executable', 'gawk')
|
||||||
call ale#Set('awk_gawk_options', '')
|
call ale#Set('awk_gawk_options', '')
|
||||||
|
@ -26,7 +26,7 @@ function! ale_linters#cpp#clangtidy#GetCommand(buffer, output) abort
|
|||||||
|
|
||||||
" Tell clang-tidy a .h header with a C++ filetype in Vim is a C++ file
|
" Tell clang-tidy a .h header with a C++ filetype in Vim is a C++ file
|
||||||
" only when compile-commands.json file is not there. Adding these
|
" only when compile-commands.json file is not there. Adding these
|
||||||
" flags makes clang-tidy completely ignore compile commmands.
|
" flags makes clang-tidy completely ignore compile commands.
|
||||||
if expand('#' . a:buffer) =~# '\.h$'
|
if expand('#' . a:buffer) =~# '\.h$'
|
||||||
let l:options .= !empty(l:options) ? ' -x c++' : '-x c++'
|
let l:options .= !empty(l:options) ? ' -x c++' : '-x c++'
|
||||||
endif
|
endif
|
||||||
|
@ -3,6 +3,7 @@
|
|||||||
" always, yes, never
|
" always, yes, never
|
||||||
call ale#Set('dockerfile_hadolint_use_docker', 'never')
|
call ale#Set('dockerfile_hadolint_use_docker', 'never')
|
||||||
call ale#Set('dockerfile_hadolint_docker_image', 'hadolint/hadolint')
|
call ale#Set('dockerfile_hadolint_docker_image', 'hadolint/hadolint')
|
||||||
|
call ale#Set('dockerfile_hadolint_options', '')
|
||||||
|
|
||||||
function! ale_linters#dockerfile#hadolint#Handle(buffer, lines) abort
|
function! ale_linters#dockerfile#hadolint#Handle(buffer, lines) abort
|
||||||
" Matches patterns line the following:
|
" Matches patterns line the following:
|
||||||
@ -102,7 +103,7 @@ endfunction
|
|||||||
|
|
||||||
function! ale_linters#dockerfile#hadolint#GetCommand(buffer) abort
|
function! ale_linters#dockerfile#hadolint#GetCommand(buffer) abort
|
||||||
let l:command = ale_linters#dockerfile#hadolint#GetExecutable(a:buffer)
|
let l:command = ale_linters#dockerfile#hadolint#GetExecutable(a:buffer)
|
||||||
let l:opts = '--no-color -'
|
let l:opts = ale#Var(a:buffer, 'dockerfile_hadolint_options') . ' --no-color -'
|
||||||
|
|
||||||
if l:command is# 'docker'
|
if l:command is# 'docker'
|
||||||
return printf('docker run --rm -i %s hadolint %s',
|
return printf('docker run --rm -i %s hadolint %s',
|
||||||
|
49
sources_non_forked/ale/ale_linters/erlang/erlang_ls.vim
Normal file
49
sources_non_forked/ale/ale_linters/erlang/erlang_ls.vim
Normal file
@ -0,0 +1,49 @@
|
|||||||
|
" Author: Dmitri Vereshchagin <dmitri.vereshchagin@gmail.com>
|
||||||
|
" Description: LSP linter for Erlang files
|
||||||
|
|
||||||
|
call ale#Set('erlang_erlang_ls_executable', 'erlang_ls')
|
||||||
|
call ale#Set('erlang_erlang_ls_log_dir', '')
|
||||||
|
call ale#Set('erlang_erlang_ls_log_level', 'info')
|
||||||
|
|
||||||
|
function! s:GetCommand(buffer) abort
|
||||||
|
let l:log_dir = ale#Var(a:buffer, 'erlang_erlang_ls_log_dir')
|
||||||
|
let l:log_level = ale#Var(a:buffer, 'erlang_erlang_ls_log_level')
|
||||||
|
|
||||||
|
let l:command = '%e'
|
||||||
|
|
||||||
|
if !empty(l:log_dir)
|
||||||
|
let l:command .= ' --log-dir=' . ale#Escape(l:log_dir)
|
||||||
|
endif
|
||||||
|
|
||||||
|
let l:command .= ' --log-level=' . ale#Escape(l:log_level)
|
||||||
|
|
||||||
|
return l:command
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! s:FindProjectRoot(buffer) abort
|
||||||
|
let l:markers = ['_build/', 'erlang_ls.config', 'rebar.lock']
|
||||||
|
|
||||||
|
" This is a way to find Erlang/OTP root (the one that is managed
|
||||||
|
" by kerl or asdf). Useful if :ALEGoToDefinition takes us there.
|
||||||
|
let l:markers += ['.kerl_config']
|
||||||
|
|
||||||
|
for l:marker in l:markers
|
||||||
|
let l:path = l:marker[-1:] is# '/'
|
||||||
|
\ ? ale#path#FindNearestDirectory(a:buffer, l:marker)
|
||||||
|
\ : ale#path#FindNearestFile(a:buffer, l:marker)
|
||||||
|
|
||||||
|
if !empty(l:path)
|
||||||
|
return ale#path#Dirname(l:path)
|
||||||
|
endif
|
||||||
|
endfor
|
||||||
|
|
||||||
|
return ''
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
call ale#linter#Define('erlang', {
|
||||||
|
\ 'name': 'erlang_ls',
|
||||||
|
\ 'executable': {b -> ale#Var(b, 'erlang_erlang_ls_executable')},
|
||||||
|
\ 'command': function('s:GetCommand'),
|
||||||
|
\ 'lsp': 'stdio',
|
||||||
|
\ 'project_root': function('s:FindProjectRoot'),
|
||||||
|
\})
|
@ -1,5 +1,7 @@
|
|||||||
" Author: aurieh - https://github.com/aurieh
|
" Author: aurieh - https://github.com/aurieh
|
||||||
|
|
||||||
|
call ale#Set('make_checkmake_config', '')
|
||||||
|
|
||||||
function! ale_linters#make#checkmake#Handle(buffer, lines) abort
|
function! ale_linters#make#checkmake#Handle(buffer, lines) abort
|
||||||
let l:pattern = '\v^(\d+):(.+):(.+)$'
|
let l:pattern = '\v^(\d+):(.+):(.+)$'
|
||||||
let l:output = []
|
let l:output = []
|
||||||
@ -17,9 +19,19 @@ function! ale_linters#make#checkmake#Handle(buffer, lines) abort
|
|||||||
return l:output
|
return l:output
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
function! ale_linters#make#checkmake#GetCommand(buffer) abort
|
||||||
|
let l:config = ale#Var(a:buffer, 'make_checkmake_config')
|
||||||
|
let l:cmd = 'checkmake'
|
||||||
|
\ . ' --format="{{.LineNumber}}:{{.Rule}}:{{.Violation}}{{\"\r\n\"}}"'
|
||||||
|
\ . (!empty(l:config) ? ' --config="' . l:config . '"' : '')
|
||||||
|
\ . ' %s'
|
||||||
|
|
||||||
|
return l:cmd
|
||||||
|
endfunction
|
||||||
|
|
||||||
call ale#linter#Define('make', {
|
call ale#linter#Define('make', {
|
||||||
\ 'name': 'checkmake',
|
\ 'name': 'checkmake',
|
||||||
\ 'executable': 'checkmake',
|
\ 'executable': 'checkmake',
|
||||||
\ 'command': 'checkmake %s --format="{{.LineNumber}}:{{.Rule}}:{{.Violation}}{{\"\r\n\"}}"',
|
\ 'command': function('ale_linters#make#checkmake#GetCommand'),
|
||||||
\ 'callback': 'ale_linters#make#checkmake#Handle',
|
\ 'callback': 'ale_linters#make#checkmake#Handle',
|
||||||
\})
|
\})
|
||||||
|
@ -1,10 +1,15 @@
|
|||||||
" Author: Ty-Lucas Kelley <tylucaskelley@gmail.com>
|
" Author: Ty-Lucas Kelley <tylucaskelley@gmail.com>
|
||||||
" Description: Adds support for markdownlint
|
" Description: Adds support for markdownlint
|
||||||
|
|
||||||
|
call ale#Set('markdown_markdownlint_executable', 'markdownlint')
|
||||||
call ale#Set('markdown_markdownlint_options', '')
|
call ale#Set('markdown_markdownlint_options', '')
|
||||||
|
|
||||||
|
function! ale_linters#markdown#markdownlint#GetExecutable(buffer) abort
|
||||||
|
return ale#Var(a:buffer, 'markdown_markdownlint_executable')
|
||||||
|
endfunction
|
||||||
|
|
||||||
function! ale_linters#markdown#markdownlint#GetCommand(buffer) abort
|
function! ale_linters#markdown#markdownlint#GetCommand(buffer) abort
|
||||||
let l:executable = 'markdownlint'
|
let l:executable = ale_linters#markdown#markdownlint#GetExecutable(a:buffer)
|
||||||
|
|
||||||
let l:options = ale#Var(a:buffer, 'markdown_markdownlint_options')
|
let l:options = ale#Var(a:buffer, 'markdown_markdownlint_options')
|
||||||
|
|
||||||
@ -14,7 +19,7 @@ endfunction
|
|||||||
|
|
||||||
call ale#linter#Define('markdown', {
|
call ale#linter#Define('markdown', {
|
||||||
\ 'name': 'markdownlint',
|
\ 'name': 'markdownlint',
|
||||||
\ 'executable': 'markdownlint',
|
\ 'executable': function('ale_linters#markdown#markdownlint#GetExecutable'),
|
||||||
\ 'lint_file': 1,
|
\ 'lint_file': 1,
|
||||||
\ 'output_stream': 'both',
|
\ 'output_stream': 'both',
|
||||||
\ 'command': function('ale_linters#markdown#markdownlint#GetCommand'),
|
\ 'command': function('ale_linters#markdown#markdownlint#GetCommand'),
|
||||||
|
@ -17,7 +17,7 @@ function! ale_linters#matlab#mlint#Handle(buffer, lines) abort
|
|||||||
let l:code = l:match[3]
|
let l:code = l:match[3]
|
||||||
let l:text = l:match[4]
|
let l:text = l:match[4]
|
||||||
|
|
||||||
" Suppress erroneous waring about filename
|
" Suppress erroneous warning about filename
|
||||||
" TODO: Enable this error when copying filename is supported
|
" TODO: Enable this error when copying filename is supported
|
||||||
if l:code is# 'FNDEF'
|
if l:code is# 'FNDEF'
|
||||||
continue
|
continue
|
||||||
|
84
sources_non_forked/ale/ale_linters/python/ruff.vim
Normal file
84
sources_non_forked/ale/ale_linters/python/ruff.vim
Normal file
@ -0,0 +1,84 @@
|
|||||||
|
" Author: Yining <zhang.yining@gmail.com>
|
||||||
|
" Description: ruff as linter for python files
|
||||||
|
|
||||||
|
call ale#Set('python_ruff_executable', 'ruff')
|
||||||
|
call ale#Set('python_ruff_options', '')
|
||||||
|
call ale#Set('python_ruff_use_global', get(g:, 'ale_use_global_executables', 0))
|
||||||
|
call ale#Set('python_ruff_change_directory', 1)
|
||||||
|
call ale#Set('python_ruff_auto_pipenv', 0)
|
||||||
|
call ale#Set('python_ruff_auto_poetry', 0)
|
||||||
|
|
||||||
|
call ale#fix#registry#Add('ruff',
|
||||||
|
\ 'ale#fixers#ruff#Fix',
|
||||||
|
\ ['python'],
|
||||||
|
\ 'A python linter/fixer for Python written in Rust'
|
||||||
|
\)
|
||||||
|
|
||||||
|
function! ale_linters#python#ruff#GetExecutable(buffer) abort
|
||||||
|
if (ale#Var(a:buffer, 'python_auto_pipenv') || ale#Var(a:buffer, 'python_ruff_auto_pipenv'))
|
||||||
|
\ && ale#python#PipenvPresent(a:buffer)
|
||||||
|
return 'pipenv'
|
||||||
|
endif
|
||||||
|
|
||||||
|
if (ale#Var(a:buffer, 'python_auto_poetry') || ale#Var(a:buffer, 'python_ruff_auto_poetry'))
|
||||||
|
\ && ale#python#PoetryPresent(a:buffer)
|
||||||
|
return 'poetry'
|
||||||
|
endif
|
||||||
|
|
||||||
|
return ale#python#FindExecutable(a:buffer, 'python_ruff', ['ruff'])
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! ale_linters#python#ruff#GetCwd(buffer) abort
|
||||||
|
if ale#Var(a:buffer, 'python_ruff_change_directory')
|
||||||
|
" Run from project root if found, else from buffer dir.
|
||||||
|
let l:project_root = ale#python#FindProjectRoot(a:buffer)
|
||||||
|
|
||||||
|
return !empty(l:project_root) ? l:project_root : '%s:h'
|
||||||
|
endif
|
||||||
|
|
||||||
|
return ''
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! ale_linters#python#ruff#GetCommand(buffer, version) abort
|
||||||
|
let l:executable = ale_linters#python#ruff#GetExecutable(a:buffer)
|
||||||
|
let l:exec_args = l:executable =~? 'pipenv\|poetry$'
|
||||||
|
\ ? ' run ruff'
|
||||||
|
\ : ''
|
||||||
|
|
||||||
|
" NOTE: ruff version `0.0.69` supports liniting input from stdin
|
||||||
|
return ale#Escape(l:executable) . l:exec_args
|
||||||
|
\ . ale#Pad(ale#Var(a:buffer, 'python_ruff_options'))
|
||||||
|
\ . ' --format text'
|
||||||
|
\ . (ale#semver#GTE(a:version, [0, 0, 69]) ? ' -' : ' %s')
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! ale_linters#python#ruff#Handle(buffer, lines) abort
|
||||||
|
"Example: path/to/file.py:10:5: E999 SyntaxError: unexpected indent
|
||||||
|
let l:pattern = '\v^[a-zA-Z]?:?[^:]+:(\d+):(\d+)?:? (.+)$'
|
||||||
|
let l:output = []
|
||||||
|
|
||||||
|
for l:match in ale#util#GetMatches(a:lines, l:pattern)
|
||||||
|
call add(l:output, {
|
||||||
|
\ 'lnum': l:match[1] + 0,
|
||||||
|
\ 'col': l:match[2] + 0,
|
||||||
|
\ 'text': l:match[3],
|
||||||
|
\})
|
||||||
|
endfor
|
||||||
|
|
||||||
|
return l:output
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
call ale#linter#Define('python', {
|
||||||
|
\ 'name': 'ruff',
|
||||||
|
\ 'executable': function('ale_linters#python#ruff#GetExecutable'),
|
||||||
|
\ 'cwd': function('ale_linters#python#ruff#GetCwd'),
|
||||||
|
\ 'command': {buffer -> ale#semver#RunWithVersionCheck(
|
||||||
|
\ buffer,
|
||||||
|
\ ale_linters#python#ruff#GetExecutable(buffer),
|
||||||
|
\ '%e --version',
|
||||||
|
\ function('ale_linters#python#ruff#GetCommand'),
|
||||||
|
\ )},
|
||||||
|
\ 'callback': 'ale_linters#python#ruff#Handle',
|
||||||
|
\ 'output_stream': 'both',
|
||||||
|
\ 'read_buffer': 1,
|
||||||
|
\})
|
72
sources_non_forked/ale/ale_linters/sql/sqlfluff.vim
Normal file
72
sources_non_forked/ale/ale_linters/sql/sqlfluff.vim
Normal file
@ -0,0 +1,72 @@
|
|||||||
|
" Author: Carl Smedstad <carl.smedstad at protonmail dot com>
|
||||||
|
" Description: sqlfluff for SQL files
|
||||||
|
|
||||||
|
let g:ale_sql_sqlfluff_executable =
|
||||||
|
\ get(g:, 'ale_sql_sqlfluff_executable', 'sqlfluff')
|
||||||
|
|
||||||
|
let g:ale_sql_sqlfluff_options =
|
||||||
|
\ get(g:, 'ale_sql_sqlfluff_options', '')
|
||||||
|
|
||||||
|
function! ale_linters#sql#sqlfluff#Executable(buffer) abort
|
||||||
|
return ale#Var(a:buffer, 'sql_sqlfluff_executable')
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! ale_linters#sql#sqlfluff#Command(buffer) abort
|
||||||
|
let l:executable = ale_linters#sql#sqlfluff#Executable(a:buffer)
|
||||||
|
let l:options = ale#Var(a:buffer, 'sql_sqlfluff_options')
|
||||||
|
|
||||||
|
let l:cmd =
|
||||||
|
\ ale#Escape(l:executable)
|
||||||
|
\ . ' lint'
|
||||||
|
|
||||||
|
let l:config_file = ale#path#FindNearestFile(a:buffer, '.sqlfluff')
|
||||||
|
|
||||||
|
if !empty(l:config_file)
|
||||||
|
let l:cmd .= ' --config ' . ale#Escape(l:config_file)
|
||||||
|
else
|
||||||
|
let l:cmd .= ' --dialect ansi'
|
||||||
|
endif
|
||||||
|
|
||||||
|
let l:cmd .=
|
||||||
|
\ ' --format json '
|
||||||
|
\ . l:options
|
||||||
|
\ . ' %t'
|
||||||
|
|
||||||
|
return l:cmd
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! ale_linters#sql#sqlfluff#Handle(buffer, lines) abort
|
||||||
|
let l:output = []
|
||||||
|
let l:json_lines = ale#util#FuzzyJSONDecode(a:lines, [])
|
||||||
|
|
||||||
|
if empty(l:json_lines)
|
||||||
|
return l:output
|
||||||
|
endif
|
||||||
|
|
||||||
|
let l:json = l:json_lines[0]
|
||||||
|
|
||||||
|
" if there's no warning, 'result' is `null`.
|
||||||
|
if empty(get(l:json, 'violations'))
|
||||||
|
return l:output
|
||||||
|
endif
|
||||||
|
|
||||||
|
for l:violation in get(l:json, 'violations', [])
|
||||||
|
call add(l:output, {
|
||||||
|
\ 'filename': l:json.filepath,
|
||||||
|
\ 'lnum': l:violation.line_no,
|
||||||
|
\ 'col': l:violation.line_pos,
|
||||||
|
\ 'text': l:violation.description,
|
||||||
|
\ 'code': l:violation.code,
|
||||||
|
\ 'type': 'W',
|
||||||
|
\})
|
||||||
|
endfor
|
||||||
|
|
||||||
|
return l:output
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
call ale#linter#Define('sql', {
|
||||||
|
\ 'name': 'sqlfluff',
|
||||||
|
\ 'executable': function('ale_linters#sql#sqlfluff#Executable'),
|
||||||
|
\ 'command': function('ale_linters#sql#sqlfluff#Command'),
|
||||||
|
\ 'callback': 'ale_linters#sql#sqlfluff#Handle',
|
||||||
|
\})
|
@ -13,7 +13,7 @@ function! ale_linters#tex#lacheck#Handle(buffer, lines) abort
|
|||||||
|
|
||||||
for l:match in ale#util#GetMatches(a:lines, l:pattern)
|
for l:match in ale#util#GetMatches(a:lines, l:pattern)
|
||||||
" lacheck follows `\input{}` commands. If the cwd is not the same as the
|
" lacheck follows `\input{}` commands. If the cwd is not the same as the
|
||||||
" file in the buffer then it will fail to find the inputed items. We do not
|
" file in the buffer then it will fail to find the inputted items. We do not
|
||||||
" want warnings from those items anyway
|
" want warnings from those items anyway
|
||||||
if !empty(matchstr(l:match[3], '^Could not open ".\+"$'))
|
if !empty(matchstr(l:match[3], '^Could not open ".\+"$'))
|
||||||
continue
|
continue
|
||||||
|
@ -216,7 +216,7 @@ function! s:UpdateCursor(cursor, start, end, offset) abort
|
|||||||
" to the end of the changes
|
" to the end of the changes
|
||||||
let l:cur_line = l:end_line + l:line_offset
|
let l:cur_line = l:end_line + l:line_offset
|
||||||
let l:cur_column = l:end_column + l:column_offset
|
let l:cur_column = l:end_column + l:column_offset
|
||||||
" else is not necesary, it means modifications are happening
|
" else is not necessary, it means modifications are happening
|
||||||
" after the cursor so no cursor updates need to be done
|
" after the cursor so no cursor updates need to be done
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
@ -130,6 +130,7 @@ let s:should_complete_map = {
|
|||||||
\ '<default>': '\v[a-zA-Z$_][a-zA-Z$_0-9]*$|\.$',
|
\ '<default>': '\v[a-zA-Z$_][a-zA-Z$_0-9]*$|\.$',
|
||||||
\ 'clojure': s:lisp_regex,
|
\ 'clojure': s:lisp_regex,
|
||||||
\ 'lisp': s:lisp_regex,
|
\ 'lisp': s:lisp_regex,
|
||||||
|
\ 'racket': '\k\+$',
|
||||||
\ 'typescript': '\v[a-zA-Z$_][a-zA-Z$_0-9]*$|\.$|''$|"$',
|
\ 'typescript': '\v[a-zA-Z$_][a-zA-Z$_0-9]*$|\.$|''$|"$',
|
||||||
\ 'rust': '\v[a-zA-Z$_][a-zA-Z$_0-9]*$|\.$|::$',
|
\ 'rust': '\v[a-zA-Z$_][a-zA-Z$_0-9]*$|\.$|::$',
|
||||||
\ 'cpp': '\v[a-zA-Z$_][a-zA-Z$_0-9]*$|\.$|::$|-\>$',
|
\ 'cpp': '\v[a-zA-Z$_][a-zA-Z$_0-9]*$|\.$|::$|-\>$',
|
||||||
|
@ -263,8 +263,8 @@ let s:default_registry = {
|
|||||||
\ },
|
\ },
|
||||||
\ 'clang-format': {
|
\ 'clang-format': {
|
||||||
\ 'function': 'ale#fixers#clangformat#Fix',
|
\ 'function': 'ale#fixers#clangformat#Fix',
|
||||||
\ 'suggested_filetypes': ['c', 'cpp', 'cuda'],
|
\ 'suggested_filetypes': ['c', 'cpp', 'cs', 'cuda', 'java', 'javascript', 'json', 'objc', 'proto'],
|
||||||
\ 'description': 'Fix C/C++ and cuda files with clang-format.',
|
\ 'description': 'Fix C, C++, C#, CUDA, Java, JavaScript, JSON, ObjectiveC and Protobuf files with clang-format.',
|
||||||
\ },
|
\ },
|
||||||
\ 'cmakeformat': {
|
\ 'cmakeformat': {
|
||||||
\ 'function': 'ale#fixers#cmakeformat#Fix',
|
\ 'function': 'ale#fixers#cmakeformat#Fix',
|
||||||
@ -386,6 +386,11 @@ let s:default_registry = {
|
|||||||
\ 'suggested_filetypes': ['sh'],
|
\ 'suggested_filetypes': ['sh'],
|
||||||
\ 'description': 'Fix sh files with shfmt.',
|
\ 'description': 'Fix sh files with shfmt.',
|
||||||
\ },
|
\ },
|
||||||
|
\ 'sqlfluff': {
|
||||||
|
\ 'function': 'ale#fixers#sqlfluff#Fix',
|
||||||
|
\ 'suggested_filetypes': ['sql'],
|
||||||
|
\ 'description': 'Fix SQL files with sqlfluff.',
|
||||||
|
\ },
|
||||||
\ 'sqlfmt': {
|
\ 'sqlfmt': {
|
||||||
\ 'function': 'ale#fixers#sqlfmt#Fix',
|
\ 'function': 'ale#fixers#sqlfmt#Fix',
|
||||||
\ 'suggested_filetypes': ['sql'],
|
\ 'suggested_filetypes': ['sql'],
|
||||||
@ -570,6 +575,11 @@ let s:default_registry = {
|
|||||||
\ 'function': 'ale#fixers#zigfmt#Fix',
|
\ 'function': 'ale#fixers#zigfmt#Fix',
|
||||||
\ 'suggested_filetypes': ['zig'],
|
\ 'suggested_filetypes': ['zig'],
|
||||||
\ 'description': 'Official formatter for Zig',
|
\ 'description': 'Official formatter for Zig',
|
||||||
|
\ },
|
||||||
|
\ 'raco_fmt': {
|
||||||
|
\ 'function': 'ale#fixers#raco_fmt#Fix',
|
||||||
|
\ 'suggested_filetypes': ['racket'],
|
||||||
|
\ 'description': 'Fix Racket files with raco fmt.',
|
||||||
\ }
|
\ }
|
||||||
\}
|
\}
|
||||||
|
|
||||||
|
15
sources_non_forked/ale/autoload/ale/fixers/raco_fmt.vim
Normal file
15
sources_non_forked/ale/autoload/ale/fixers/raco_fmt.vim
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
" Author: Jeremy Cantrell <jmcantrell@gmail.com>
|
||||||
|
" Description: Integration of raco fmt with ALE.
|
||||||
|
|
||||||
|
call ale#Set('racket_raco_fmt_executable', 'raco')
|
||||||
|
call ale#Set('racket_raco_fmt_options', '')
|
||||||
|
|
||||||
|
function! ale#fixers#raco_fmt#Fix(buffer) abort
|
||||||
|
let l:executable = ale#Var(a:buffer, 'racket_raco_fmt_executable')
|
||||||
|
let l:options = ale#Var(a:buffer, 'racket_raco_fmt_options')
|
||||||
|
|
||||||
|
return {
|
||||||
|
\ 'command': ale#Escape(l:executable) . ' fmt'
|
||||||
|
\ . (empty(l:options) ? '' : ' ' . l:options),
|
||||||
|
\}
|
||||||
|
endfunction
|
54
sources_non_forked/ale/autoload/ale/fixers/ruff.vim
Normal file
54
sources_non_forked/ale/autoload/ale/fixers/ruff.vim
Normal file
@ -0,0 +1,54 @@
|
|||||||
|
" Author: Yining <zhang.yining@gmail.com>
|
||||||
|
" Description: ruff as ALE fixer for python files
|
||||||
|
|
||||||
|
function! ale#fixers#ruff#GetCwd(buffer) abort
|
||||||
|
if ale#Var(a:buffer, 'python_ruff_change_directory')
|
||||||
|
" Run from project root if found, else from buffer dir.
|
||||||
|
let l:project_root = ale#python#FindProjectRoot(a:buffer)
|
||||||
|
|
||||||
|
return !empty(l:project_root) ? l:project_root : '%s:h'
|
||||||
|
endif
|
||||||
|
|
||||||
|
return ''
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! ale#fixers#ruff#GetExecutable(buffer) abort
|
||||||
|
if (ale#Var(a:buffer, 'python_auto_pipenv') || ale#Var(a:buffer, 'python_ruff_auto_pipenv'))
|
||||||
|
\ && ale#python#PipenvPresent(a:buffer)
|
||||||
|
return 'pipenv'
|
||||||
|
endif
|
||||||
|
|
||||||
|
if (ale#Var(a:buffer, 'python_auto_poetry') || ale#Var(a:buffer, 'python_ruff_auto_poetry'))
|
||||||
|
\ && ale#python#PoetryPresent(a:buffer)
|
||||||
|
return 'poetry'
|
||||||
|
endif
|
||||||
|
|
||||||
|
return ale#python#FindExecutable(a:buffer, 'python_ruff', ['ruff'])
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! ale#fixers#ruff#GetCommand(buffer, version) abort
|
||||||
|
let l:executable = ale_linters#python#ruff#GetExecutable(a:buffer)
|
||||||
|
let l:exec_args = l:executable =~? 'pipenv\|poetry$'
|
||||||
|
\ ? ' run ruff'
|
||||||
|
\ : ''
|
||||||
|
|
||||||
|
" NOTE: ruff version `0.0.72` implement `--fix` with stdin
|
||||||
|
return ale#Escape(l:executable) . l:exec_args
|
||||||
|
\ . ale#Pad(ale#Var(a:buffer, 'python_ruff_options'))
|
||||||
|
\ . ' --fix'
|
||||||
|
\ . (ale#semver#GTE(a:version, [0, 0, 72]) ? ' -' : ' %s')
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! ale#fixers#ruff#Fix(buffer) abort
|
||||||
|
let l:fix_cmd = {buffer -> ale#semver#RunWithVersionCheck(
|
||||||
|
\ buffer,
|
||||||
|
\ ale#fixers#ruff#GetExecutable(buffer),
|
||||||
|
\ '%e --version',
|
||||||
|
\ function('ale#fixers#ruff#GetCommand'),
|
||||||
|
\ )}(a:buffer)
|
||||||
|
|
||||||
|
return {
|
||||||
|
\ 'cwd': ale#fixers#ruff#GetCwd(a:buffer),
|
||||||
|
\ 'command': l:fix_cmd,
|
||||||
|
\}
|
||||||
|
endfunction
|
25
sources_non_forked/ale/autoload/ale/fixers/sqlfluff.vim
Normal file
25
sources_non_forked/ale/autoload/ale/fixers/sqlfluff.vim
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
" Author: Carl Smedstad <carl.smedstad at protonmail dot com>
|
||||||
|
" Description: Fixing SQL files with sqlfluff
|
||||||
|
|
||||||
|
call ale#Set('sql_sqlfluff_executable', 'sqlfluff')
|
||||||
|
|
||||||
|
function! ale#fixers#sqlfluff#Fix(buffer) abort
|
||||||
|
let l:executable = ale#Var(a:buffer, 'sql_sqlfluff_executable')
|
||||||
|
|
||||||
|
let l:cmd =
|
||||||
|
\ ale#Escape(l:executable)
|
||||||
|
\ . ' fix --force'
|
||||||
|
|
||||||
|
let l:config_file = ale#path#FindNearestFile(a:buffer, '.sqlfluff')
|
||||||
|
|
||||||
|
if !empty(l:config_file)
|
||||||
|
let l:cmd .= ' --config ' . ale#Escape(l:config_file)
|
||||||
|
else
|
||||||
|
let l:cmd .= ' --dialect ansi'
|
||||||
|
endif
|
||||||
|
|
||||||
|
return {
|
||||||
|
\ 'command': l:cmd . ' %t > /dev/null',
|
||||||
|
\ 'read_temporary_file': 1,
|
||||||
|
\}
|
||||||
|
endfunction
|
@ -13,7 +13,7 @@ function! ale#handlers#hdl_checker#IsDotGit(path) abort
|
|||||||
return ! empty(a:path) && isdirectory(a:path)
|
return ! empty(a:path) && isdirectory(a:path)
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
" Sould return (in order of preference)
|
" Should return (in order of preference)
|
||||||
" 1. Nearest config file
|
" 1. Nearest config file
|
||||||
" 2. Nearest .git directory
|
" 2. Nearest .git directory
|
||||||
" 3. The current path
|
" 3. The current path
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
" Author: Horacio Sanson https://github.com/hsanson
|
" Author: Horacio Sanson https://github.com/hsanson
|
||||||
" Description: Functions for integrating with Java tools
|
" Description: Functions for integrating with Java tools
|
||||||
|
|
||||||
" Find the nearest dir contining a gradle or pom file and asume it
|
" Find the nearest dir contining a gradle or pom file and assume it
|
||||||
" the root of a java app.
|
" the root of a java app.
|
||||||
function! ale#java#FindProjectRoot(buffer) abort
|
function! ale#java#FindProjectRoot(buffer) abort
|
||||||
let l:gradle_root = ale#gradle#FindProjectRoot(a:buffer)
|
let l:gradle_root = ale#gradle#FindProjectRoot(a:buffer)
|
||||||
|
@ -18,7 +18,7 @@ if !exists('s:timer_args')
|
|||||||
let s:timer_args = {}
|
let s:timer_args = {}
|
||||||
endif
|
endif
|
||||||
|
|
||||||
" Return 1 if there is a buffer with buftype == 'quickfix' in bufffer list
|
" Return 1 if there is a buffer with buftype == 'quickfix' in buffer list
|
||||||
function! ale#list#IsQuickfixOpen() abort
|
function! ale#list#IsQuickfixOpen() abort
|
||||||
let l:res = getqflist({ 'winid' : winnr() })
|
let l:res = getqflist({ 'winid' : winnr() })
|
||||||
|
|
||||||
@ -190,7 +190,7 @@ function! s:RestoreViewIfNeeded(buffer) abort
|
|||||||
return
|
return
|
||||||
endif
|
endif
|
||||||
|
|
||||||
" Check wether the cursor has moved since linting was actually requested. If
|
" Check whether the cursor has moved since linting was actually requested. If
|
||||||
" the user has indeed moved lines, do nothing
|
" the user has indeed moved lines, do nothing
|
||||||
let l:current_view = winsaveview()
|
let l:current_view = winsaveview()
|
||||||
|
|
||||||
|
@ -434,7 +434,7 @@ function! ale#lsp_linter#StartLSP(buffer, linter, Callback) abort
|
|||||||
if empty(l:root) && a:linter.lsp isnot# 'tsserver'
|
if empty(l:root) && a:linter.lsp isnot# 'tsserver'
|
||||||
" If there's no project root, then we can't check files with LSP,
|
" If there's no project root, then we can't check files with LSP,
|
||||||
" unless we are using tsserver, which doesn't use project roots.
|
" unless we are using tsserver, which doesn't use project roots.
|
||||||
call ale#lsp_linter#AddErrorMessage(a:linter.name, "Failed to find project root, language server wont't start.")
|
call ale#lsp_linter#AddErrorMessage(a:linter.name, "Failed to find project root, language server won't start.")
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
endif
|
endif
|
||||||
|
@ -1,6 +1,28 @@
|
|||||||
===============================================================================
|
===============================================================================
|
||||||
ALE Ansible Integration *ale-ansible-options*
|
ALE Ansible Integration *ale-ansible-options*
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
ansible-language-server *ale-ansible-language-server*
|
||||||
|
|
||||||
|
|
||||||
|
g:ale_ansible_language_server_executable *g:ale_ansible_language_server*
|
||||||
|
*b:ale_ansible_language_server*
|
||||||
|
|
||||||
|
Type: |String|
|
||||||
|
Default: 'ansible-language-server'
|
||||||
|
|
||||||
|
Variable can be used to modify the executable used for ansible language server.
|
||||||
|
|
||||||
|
|
||||||
|
g:ale_ansible_language_server_config *g:ale_ansible_language_server_config*
|
||||||
|
*b:ale_ansible_language_server_config*
|
||||||
|
|
||||||
|
Type: |Dictionary|
|
||||||
|
Default: '{}'
|
||||||
|
|
||||||
|
Configuration parameters sent to the language server on start. Refer to the
|
||||||
|
ansible language server configuration documentation for list of available
|
||||||
|
options: https://als.readthedocs.io/en/latest/settings/
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
ansible-lint *ale-ansible-ansible-lint*
|
ansible-lint *ale-ansible-ansible-lint*
|
||||||
@ -12,5 +34,6 @@ g:ale_ansible_ansible_lint_executable *g:ale_ansible_ansible_lint_executable*
|
|||||||
|
|
||||||
This variable can be changed to modify the executable used for ansible-lint.
|
This variable can be changed to modify the executable used for ansible-lint.
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
vim:tw=78:ts=2:sts=2:sw=2:ft=help:norl:
|
vim:tw=78:ts=2:sts=2:sw=2:ft=help:norl:
|
||||||
|
@ -6,6 +6,13 @@ In addition to the linters that are provided with ALE, C# code can be checked
|
|||||||
with the OmniSharp plugin. See here: https://github.com/OmniSharp/omnisharp-vim
|
with the OmniSharp plugin. See here: https://github.com/OmniSharp/omnisharp-vim
|
||||||
|
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
clang-format *ale-cs-clangformat*
|
||||||
|
|
||||||
|
See |ale-c-clangformat| for information about the available options.
|
||||||
|
Note that the C options are also used for C#.
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
csc *ale-cs-csc*
|
csc *ale-cs-csc*
|
||||||
|
|
||||||
|
@ -2,6 +2,32 @@
|
|||||||
ALE CUDA Integration *ale-cuda-options*
|
ALE CUDA Integration *ale-cuda-options*
|
||||||
|
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
clang-format *ale-cuda-clangformat*
|
||||||
|
|
||||||
|
See |ale-c-clangformat| for information about the available options.
|
||||||
|
Note that the C options are also used for CUDA.
|
||||||
|
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
clangd *ale-cuda-clangd*
|
||||||
|
|
||||||
|
g:ale_cuda_clangd_executable *g:ale_cuda_clangd_executable*
|
||||||
|
*b:ale_cuda_clangd_executable*
|
||||||
|
Type: |String|
|
||||||
|
Default: `'clangd'`
|
||||||
|
|
||||||
|
This variable can be changed to use a different executable for clangd.
|
||||||
|
|
||||||
|
|
||||||
|
g:ale_cuda_clangd_options *g:ale_cuda_clangd_options*
|
||||||
|
*b:ale_cuda_clangd_options*
|
||||||
|
Type: |String|
|
||||||
|
Default: `''`
|
||||||
|
|
||||||
|
This variable can be changed to modify flags given to clangd.
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
nvcc *ale-cuda-nvcc*
|
nvcc *ale-cuda-nvcc*
|
||||||
|
|
||||||
@ -21,30 +47,6 @@ g:ale_cuda_nvcc_options *g:ale_cuda_nvcc_options*
|
|||||||
|
|
||||||
This variable can be changed to modify flags given to nvcc.
|
This variable can be changed to modify flags given to nvcc.
|
||||||
|
|
||||||
===============================================================================
|
|
||||||
clangd *ale-cuda-clangd*
|
|
||||||
|
|
||||||
g:ale_cuda_clangd_executable *g:ale_cuda_clangd_executable*
|
|
||||||
*b:ale_cuda_clangd_executable*
|
|
||||||
Type: |String|
|
|
||||||
Default: `'clangd'`
|
|
||||||
|
|
||||||
This variable can be changed to use a different executable for clangd.
|
|
||||||
|
|
||||||
|
|
||||||
g:ale_cuda_clangd_options *g:ale_cuda_clangd_options*
|
|
||||||
*b:ale_cuda_clangd_options*
|
|
||||||
Type: |String|
|
|
||||||
Default: `''`
|
|
||||||
|
|
||||||
This variable can be changed to modify flags given to clangd.
|
|
||||||
|
|
||||||
===============================================================================
|
|
||||||
clang-format *ale-cuda-clangformat*
|
|
||||||
|
|
||||||
See |ale-c-clangformat| for information about the available options.
|
|
||||||
Note that the C options are also used for cuda.
|
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
vim:tw=78:ts=2:sts=2:sw=2:ft=help:norl:
|
vim:tw=78:ts=2:sts=2:sw=2:ft=help:norl:
|
||||||
|
@ -154,9 +154,9 @@ ALE runs tests with the following versions of Vim in the following
|
|||||||
environments.
|
environments.
|
||||||
|
|
||||||
1. Vim 8.0.0027 on Linux via GitHub Actions.
|
1. Vim 8.0.0027 on Linux via GitHub Actions.
|
||||||
2. Vim 8.2.4693 on Linux via GitHub Actions.
|
2. Vim 9.0.0133 on Linux via GitHub Actions.
|
||||||
3. NeoVim 0.2.0 on Linux via GitHub Actions.
|
3. NeoVim 0.2.0 on Linux via GitHub Actions.
|
||||||
4. NeoVim 0.7.0 on Linux via GitHub Actions.
|
4. NeoVim 0.8.0 on Linux via GitHub Actions.
|
||||||
6. Vim 8 (stable builds) on Windows via AppVeyor.
|
6. Vim 8 (stable builds) on Windows via AppVeyor.
|
||||||
|
|
||||||
If you are developing ALE code on Linux, Mac OSX, or BSD, you can run ALEs
|
If you are developing ALE code on Linux, Mac OSX, or BSD, you can run ALEs
|
||||||
|
@ -37,6 +37,16 @@ hadolint *ale-dockerfile-hadolint*
|
|||||||
hadolint can be found at: https://github.com/hadolint/hadolint
|
hadolint can be found at: https://github.com/hadolint/hadolint
|
||||||
|
|
||||||
|
|
||||||
|
g:ale_dockerfile_hadolint_options *g:ale_dockerfile_hadolint_options*
|
||||||
|
*b:ale_dockerfile_hadolint_options*
|
||||||
|
Type: |String|
|
||||||
|
Default: `''`
|
||||||
|
|
||||||
|
This variable can be changed to add command-line arguments to the hadolint
|
||||||
|
invocation. These arguments will be used whether docker is being used or not
|
||||||
|
(see below).
|
||||||
|
|
||||||
|
|
||||||
g:ale_dockerfile_hadolint_use_docker *g:ale_dockerfile_hadolint_use_docker*
|
g:ale_dockerfile_hadolint_use_docker *g:ale_dockerfile_hadolint_use_docker*
|
||||||
*b:ale_dockerfile_hadolint_use_docker*
|
*b:ale_dockerfile_hadolint_use_docker*
|
||||||
Type: |String|
|
Type: |String|
|
||||||
|
@ -51,6 +51,31 @@ g:ale_erlang_elvis_executable *g:ale_erlang_elvis_executable*
|
|||||||
This variable can be changed to specify the elvis executable.
|
This variable can be changed to specify the elvis executable.
|
||||||
|
|
||||||
|
|
||||||
|
-------------------------------------------------------------------------------
|
||||||
|
erlang_ls *ale-erlang-erlang_ls*
|
||||||
|
|
||||||
|
g:ale_erlang_erlang_ls_executable *g:ale_erlang_erlang_ls_executable*
|
||||||
|
*b:ale_erlang_erlang_ls_executable*
|
||||||
|
Type: |String|
|
||||||
|
Default: `'erlang_ls'`
|
||||||
|
|
||||||
|
This variable can be changed to specify the erlang_ls executable.
|
||||||
|
|
||||||
|
g:ale_erlang_erlang_ls_log_dir *g:ale_erlang_erlang_ls_log_dir*
|
||||||
|
*b:ale_erlang_erlang_ls_log_dir*
|
||||||
|
Type: |String|
|
||||||
|
Default: `''`
|
||||||
|
|
||||||
|
If set this variable overrides default directory where logs will be written.
|
||||||
|
|
||||||
|
g:ale_erlang_erlang_ls_log_level *g:ale_erlang_erlang_ls_log_level*
|
||||||
|
*b:ale_erlang_erlang_ls_log_level*
|
||||||
|
Type: |String|
|
||||||
|
Default: `'info'`
|
||||||
|
|
||||||
|
This variable can be changed to specify log level.
|
||||||
|
|
||||||
|
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
erlc *ale-erlang-erlc*
|
erlc *ale-erlang-erlc*
|
||||||
|
|
||||||
|
@ -39,7 +39,7 @@ ruumba *ale-eruby-ruumba*
|
|||||||
|
|
||||||
g:ale_eruby_ruumba_executable *g:ale_eruby_ruumba_executable*
|
g:ale_eruby_ruumba_executable *g:ale_eruby_ruumba_executable*
|
||||||
*b:ale_eruby_ruumba_executable*
|
*b:ale_eruby_ruumba_executable*
|
||||||
Type: String
|
Type: |String|
|
||||||
Default: `'ruumba`
|
Default: `'ruumba`
|
||||||
|
|
||||||
Override the invoked ruumba binary. This is useful for running ruumba
|
Override the invoked ruumba binary. This is useful for running ruumba
|
||||||
|
@ -169,7 +169,7 @@ g:ale_go_golines_executable *g:ale_go_lines_executable*
|
|||||||
g:ale_go_golines_options *g:ale_go_golines_options*
|
g:ale_go_golines_options *g:ale_go_golines_options*
|
||||||
*b:ale_go_golines_options*
|
*b:ale_go_golines_options*
|
||||||
Type: |String|
|
Type: |String|
|
||||||
Default: ''
|
Default: `''`
|
||||||
|
|
||||||
Additional options passed to the golines command. By default golines has
|
Additional options passed to the golines command. By default golines has
|
||||||
--max-length=100 (lines above 100 characters will be wrapped)
|
--max-length=100 (lines above 100 characters will be wrapped)
|
||||||
|
@ -123,8 +123,8 @@ g:ale_haskell_hlint_executable *g:ale_haskell_hlint_executable*
|
|||||||
|
|
||||||
g:ale_haskell_hlint_options g:ale_haskell_hlint_options
|
g:ale_haskell_hlint_options g:ale_haskell_hlint_options
|
||||||
b:ale_haskell_hlint_options
|
b:ale_haskell_hlint_options
|
||||||
Type: String
|
Type: |String|
|
||||||
Default: ''
|
Default: `''`
|
||||||
|
|
||||||
This variable can be used to pass extra options to the underlying hlint
|
This variable can be used to pass extra options to the underlying hlint
|
||||||
executable.
|
executable.
|
||||||
@ -217,8 +217,8 @@ g:ale_haskell_ormolu_executable *g:ale_haskell_ormolu_executable*
|
|||||||
|
|
||||||
g:ale_haskell_ormolu_options *g:ale_haskell_ormolu_options*
|
g:ale_haskell_ormolu_options *g:ale_haskell_ormolu_options*
|
||||||
*b:ale_haskell_ormolu_options*
|
*b:ale_haskell_ormolu_options*
|
||||||
Type: String
|
Type: |String|
|
||||||
Default: ''
|
Default: `''`
|
||||||
|
|
||||||
This variable can be used to pass extra options to the underlying ormolu
|
This variable can be used to pass extra options to the underlying ormolu
|
||||||
executable.
|
executable.
|
||||||
|
@ -24,7 +24,7 @@ g:ale_java_checkstyle_executable *g:ale_java_checkstyle_executable*
|
|||||||
*b:ale_java_checkstyle_executable*
|
*b:ale_java_checkstyle_executable*
|
||||||
|
|
||||||
Type: |String|
|
Type: |String|
|
||||||
Default: 'checkstyle'
|
Default: `'checkstyle'`
|
||||||
|
|
||||||
This variable can be changed to modify the executable used for checkstyle.
|
This variable can be changed to modify the executable used for checkstyle.
|
||||||
|
|
||||||
@ -41,6 +41,13 @@ g:ale_java_checkstyle_options *g:ale_java_checkstyle_options*
|
|||||||
configuration files set with |g:ale_java_checkstyle_config|.
|
configuration files set with |g:ale_java_checkstyle_config|.
|
||||||
|
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
clang-format *ale-java-clangformat*
|
||||||
|
|
||||||
|
See |ale-c-clangformat| for information about the available options.
|
||||||
|
Note that the C options are also used for Java.
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
cspell *ale-java-cspell*
|
cspell *ale-java-cspell*
|
||||||
|
|
||||||
@ -124,8 +131,8 @@ pmd *ale-java-pmd*
|
|||||||
g:ale_java_pmd_options *g:ale_java_pmd_options*
|
g:ale_java_pmd_options *g:ale_java_pmd_options*
|
||||||
*b:ale_java_pmd_options*
|
*b:ale_java_pmd_options*
|
||||||
|
|
||||||
Type: String
|
Type: |String|
|
||||||
Default: '-R category/java/bestpractices'
|
Default: `'-R category/java/bestpractices'`
|
||||||
|
|
||||||
This variable can be changed to modify flags given to PMD. Do not specify -f
|
This variable can be changed to modify flags given to PMD. Do not specify -f
|
||||||
and -d. They are added automatically.
|
and -d. They are added automatically.
|
||||||
@ -173,7 +180,7 @@ g:ale_java_javalsp_config *g:ale_java_javalsp_config*
|
|||||||
Type: |Dictionary|
|
Type: |Dictionary|
|
||||||
Default: `{}`
|
Default: `{}`
|
||||||
|
|
||||||
The javalsp linter automatically detects external depenencies for Maven and
|
The javalsp linter automatically detects external dependencies for Maven and
|
||||||
Gradle projects. In case the javalsp fails to detect some of them, you can
|
Gradle projects. In case the javalsp fails to detect some of them, you can
|
||||||
specify them setting a dictionary to |g:ale_java_javalsp_config| variable.
|
specify them setting a dictionary to |g:ale_java_javalsp_config| variable.
|
||||||
>
|
>
|
||||||
|
@ -17,12 +17,21 @@ You should change the structure of your project from this: >
|
|||||||
/path/foo/.eslintrc.js # root: true
|
/path/foo/.eslintrc.js # root: true
|
||||||
/path/foo/bar/.eslintrc.js # root: false
|
/path/foo/bar/.eslintrc.js # root: false
|
||||||
<
|
<
|
||||||
|
|
||||||
To this: >
|
To this: >
|
||||||
/path/foo/.base-eslintrc.js # Base configuration here
|
/path/foo/.base-eslintrc.js # Base configuration here
|
||||||
/path/foo/.eslintrc.js # extends: ["/path/foo/.base-eslintrc.js"]
|
/path/foo/.eslintrc.js # extends: ["/path/foo/.base-eslintrc.js"]
|
||||||
/path/foo/bar/.eslintrc.js # extends: ["/path/foo/.base-eslintrc.js"]
|
/path/foo/bar/.eslintrc.js # extends: ["/path/foo/.base-eslintrc.js"]
|
||||||
<
|
<
|
||||||
|
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
clang-format *ale-javascript-clangformat*
|
||||||
|
|
||||||
|
See |ale-c-clangformat| for information about the available options.
|
||||||
|
Note that the C options are also used for JavaScript.
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
cspell *ale-javascript-cspell*
|
cspell *ale-javascript-cspell*
|
||||||
|
|
||||||
|
@ -2,6 +2,13 @@
|
|||||||
ALE JSON Integration *ale-json-options*
|
ALE JSON Integration *ale-json-options*
|
||||||
|
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
clang-format *ale-json-clangformat*
|
||||||
|
|
||||||
|
See |ale-c-clangformat| for information about the available options.
|
||||||
|
Note that the C options are also used for JSON.
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
cspell *ale-json-cspell*
|
cspell *ale-json-cspell*
|
||||||
|
|
||||||
|
@ -11,7 +11,7 @@ g:ale_julia_executable *g:ale_julia_executable*
|
|||||||
*b:ale_julia_executable*
|
*b:ale_julia_executable*
|
||||||
|
|
||||||
Type: |String|
|
Type: |String|
|
||||||
Default: 'julia'
|
Default: `'julia'`
|
||||||
|
|
||||||
Path to the julia exetuable.
|
Path to the julia exetuable.
|
||||||
|
|
||||||
|
@ -79,7 +79,7 @@ g:ale_kotlin_ktlint_executable *g:ale_kotlin_ktlint_executable*
|
|||||||
|
|
||||||
g:ale_kotlin_ktlint_rulesets *g:ale_kotlin_ktlint_rulesets*
|
g:ale_kotlin_ktlint_rulesets *g:ale_kotlin_ktlint_rulesets*
|
||||||
Type: |List| of |String|s
|
Type: |List| of |String|s
|
||||||
Default: []
|
Default: `[]`
|
||||||
|
|
||||||
This list should contain paths to ruleset jars and/or strings of maven
|
This list should contain paths to ruleset jars and/or strings of maven
|
||||||
artifact triples. Example:
|
artifact triples. Example:
|
||||||
|
@ -9,7 +9,7 @@ g:ale_llvm_llc_executable *g:ale_llvm_llc_executable*
|
|||||||
*b:ale_llvm_llc_executable*
|
*b:ale_llvm_llc_executable*
|
||||||
|
|
||||||
Type: |String|
|
Type: |String|
|
||||||
Default: "llc"
|
Default: `"llc"`
|
||||||
|
|
||||||
The command to use for checking. This variable is useful when llc command
|
The command to use for checking. This variable is useful when llc command
|
||||||
has suffix like "llc-5.0".
|
has suffix like "llc-5.0".
|
||||||
|
18
sources_non_forked/ale/doc/ale-make.txt
Normal file
18
sources_non_forked/ale/doc/ale-make.txt
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
===============================================================================
|
||||||
|
ALE Make Integration *ale-make-options*
|
||||||
|
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
checkmake *ale-make-checkmake*
|
||||||
|
|
||||||
|
g:ale_make_checkmake_config *g:ale_make_checkmake_config*
|
||||||
|
*b:ale_make_checkmake_config*
|
||||||
|
Type: |String|
|
||||||
|
Default: `''`
|
||||||
|
|
||||||
|
This variable can be used to set the `--config` option of checkmake command.
|
||||||
|
if the value is empty, the checkmake command will not be invoked with the
|
||||||
|
option.
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
vim:tw=78:ts=2:sts=2:sw=2:ft=help:norl:
|
@ -17,6 +17,15 @@ See |ale-dprint-options| and https://dprint.dev/plugins/markdown
|
|||||||
===============================================================================
|
===============================================================================
|
||||||
markdownlint *ale-markdown-markdownlint*
|
markdownlint *ale-markdown-markdownlint*
|
||||||
|
|
||||||
|
g:ale_markdown_markdown_executable *g:ale_markdown_markdownlint_executable*
|
||||||
|
*b:ale_markdown_markdownlint_executable*
|
||||||
|
Type: |String|
|
||||||
|
Default: `'markdownlint'`
|
||||||
|
|
||||||
|
Override the invoked markdownlint binary. You can use other binaries such as
|
||||||
|
markdownlint-cli2.
|
||||||
|
|
||||||
|
|
||||||
g:ale_markdown_markdownlint_options *g:ale_markdown_markdownlint_options*
|
g:ale_markdown_markdownlint_options *g:ale_markdown_markdownlint_options*
|
||||||
*b:ale_markdown_markdownlint_options*
|
*b:ale_markdown_markdownlint_options*
|
||||||
Type: |String|
|
Type: |String|
|
||||||
|
@ -2,42 +2,6 @@
|
|||||||
ALE Objective-C Integration *ale-objc-options*
|
ALE Objective-C Integration *ale-objc-options*
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
|
||||||
clang *ale-objc-clang*
|
|
||||||
|
|
||||||
g:ale_objc_clang_options *g:ale_objc_clang_options*
|
|
||||||
*b:ale_objc_clang_options*
|
|
||||||
Type: |String|
|
|
||||||
Default: `'-std=c11 -Wall'`
|
|
||||||
|
|
||||||
This variable can be changed to modify flags given to clang.
|
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
|
||||||
clangd *ale-objc-clangd*
|
|
||||||
|
|
||||||
g:ale_objc_clangd_executable *g:ale_objc_clangd_executable*
|
|
||||||
*b:ale_objc_clangd_executable*
|
|
||||||
Type: |String|
|
|
||||||
Default: `'clangd'`
|
|
||||||
|
|
||||||
This variable can be changed to use a different executable for clangd.
|
|
||||||
|
|
||||||
|
|
||||||
g:ale_objc_clangd_options *g:ale_objc_clangd_options*
|
|
||||||
*b:ale_objc_clangd_options*
|
|
||||||
Type: |String|
|
|
||||||
Default: `''`
|
|
||||||
|
|
||||||
This variable can be changed to modify flags given to clangd.
|
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
|
||||||
uncrustify *ale-objc-uncrustify*
|
|
||||||
|
|
||||||
See |ale-c-uncrustify| for information about the available options.
|
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
ccls *ale-objc-ccls*
|
ccls *ale-objc-ccls*
|
||||||
|
|
||||||
@ -69,5 +33,48 @@ g:ale_objc_ccls_init_options *g:ale_objc_ccls_init_options*
|
|||||||
available options and explanations.
|
available options and explanations.
|
||||||
|
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
clang *ale-objc-clang*
|
||||||
|
|
||||||
|
g:ale_objc_clang_options *g:ale_objc_clang_options*
|
||||||
|
*b:ale_objc_clang_options*
|
||||||
|
Type: |String|
|
||||||
|
Default: `'-std=c11 -Wall'`
|
||||||
|
|
||||||
|
This variable can be changed to modify flags given to clang.
|
||||||
|
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
clang-format *ale-objc-clangformat*
|
||||||
|
|
||||||
|
See |ale-c-clangformat| for information about the available options.
|
||||||
|
Note that the C options are also used for Objective-C.
|
||||||
|
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
clangd *ale-objc-clangd*
|
||||||
|
|
||||||
|
g:ale_objc_clangd_executable *g:ale_objc_clangd_executable*
|
||||||
|
*b:ale_objc_clangd_executable*
|
||||||
|
Type: |String|
|
||||||
|
Default: `'clangd'`
|
||||||
|
|
||||||
|
This variable can be changed to use a different executable for clangd.
|
||||||
|
|
||||||
|
|
||||||
|
g:ale_objc_clangd_options *g:ale_objc_clangd_options*
|
||||||
|
*b:ale_objc_clangd_options*
|
||||||
|
Type: |String|
|
||||||
|
Default: `''`
|
||||||
|
|
||||||
|
This variable can be changed to modify flags given to clangd.
|
||||||
|
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
uncrustify *ale-objc-uncrustify*
|
||||||
|
|
||||||
|
See |ale-c-uncrustify| for information about the available options.
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
vim:tw=78:ts=2:sts=2:sw=2:ft=help:norl:
|
vim:tw=78:ts=2:sts=2:sw=2:ft=help:norl:
|
||||||
|
@ -72,7 +72,7 @@ g:ale_perl_perlcritic_options *g:ale_perl_perlcritic_options*
|
|||||||
g:ale_perl_perlcritic_showrules *g:ale_perl_perlcritic_showrules*
|
g:ale_perl_perlcritic_showrules *g:ale_perl_perlcritic_showrules*
|
||||||
|
|
||||||
Type: |Number|
|
Type: |Number|
|
||||||
Default: 0
|
Default: `0`
|
||||||
|
|
||||||
Controls whether perlcritic rule names are shown after the error message.
|
Controls whether perlcritic rule names are shown after the error message.
|
||||||
Defaults to off to reduce length of message.
|
Defaults to off to reduce length of message.
|
||||||
|
@ -13,7 +13,7 @@ powershell *ale-powershell-powershell*
|
|||||||
|
|
||||||
g:ale_powershell_powershell_executable *g:ale_powershell_powershell_executable*
|
g:ale_powershell_powershell_executable *g:ale_powershell_powershell_executable*
|
||||||
*b:ale_powershell_powershell_executable*
|
*b:ale_powershell_powershell_executable*
|
||||||
Type: String
|
Type: |String|
|
||||||
Default: `'pwsh'`
|
Default: `'pwsh'`
|
||||||
|
|
||||||
This variable can be changed to use a different executable for powershell.
|
This variable can be changed to use a different executable for powershell.
|
||||||
|
@ -9,12 +9,15 @@ To enable `.proto` file linting, update |g:ale_linters| as appropriate:
|
|||||||
>
|
>
|
||||||
" Enable linter for .proto files
|
" Enable linter for .proto files
|
||||||
let g:ale_linters = {'proto': ['buf-lint', 'protoc-gen-lint', 'protolint']}
|
let g:ale_linters = {'proto': ['buf-lint', 'protoc-gen-lint', 'protolint']}
|
||||||
|
<
|
||||||
|
|
||||||
To enable `.proto` file fixing, update |g:ale_fixers| as appropriate:
|
To enable `.proto` file fixing, update |g:ale_fixers| as appropriate:
|
||||||
>
|
>
|
||||||
" Enable linter for .proto files
|
" Enable linter for .proto files
|
||||||
let b:ale_fixers = {'proto': ['buf-format', 'protolint']}
|
let b:ale_fixers = {'proto': ['buf-format', 'protolint']}
|
||||||
<
|
<
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
buf-format *ale-proto-buf-format*
|
buf-format *ale-proto-buf-format*
|
||||||
|
|
||||||
@ -25,10 +28,11 @@ buf-format *ale-proto-buf-format*
|
|||||||
g:ale_proto_buf_format_executable *g:ale_proto_buf_format_executable*
|
g:ale_proto_buf_format_executable *g:ale_proto_buf_format_executable*
|
||||||
|
|
||||||
Type: |String|
|
Type: |String|
|
||||||
Default: 'buf'
|
Default: `'buf'`
|
||||||
|
|
||||||
This variable can be changed to modify the executable used for buf.
|
This variable can be changed to modify the executable used for buf.
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
buf-lint *ale-proto-buf-lint*
|
buf-lint *ale-proto-buf-lint*
|
||||||
|
|
||||||
@ -39,7 +43,7 @@ buf-lint *ale-proto-buf-lint*
|
|||||||
g:ale_proto_buf_lint_executable *g:ale_proto_buf_lint_executable*
|
g:ale_proto_buf_lint_executable *g:ale_proto_buf_lint_executable*
|
||||||
|
|
||||||
Type: |String|
|
Type: |String|
|
||||||
Default: 'buf'
|
Default: `'buf'`
|
||||||
|
|
||||||
This variable can be changed to modify the executable used for buf.
|
This variable can be changed to modify the executable used for buf.
|
||||||
|
|
||||||
@ -53,6 +57,14 @@ g:ale_proto_buf_lint_config *g:ale_proto_buf_lint_config*
|
|||||||
The path to the configuration file can be an absolute path or a relative
|
The path to the configuration file can be an absolute path or a relative
|
||||||
path. ALE will search for the relative path in parent directories.
|
path. ALE will search for the relative path in parent directories.
|
||||||
|
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
clang-format *ale-proto-clangformat*
|
||||||
|
|
||||||
|
See |ale-c-clangformat| for information about the available options.
|
||||||
|
Note that the C options are also used for Proto.
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
protoc-gen-lint *ale-proto-protoc-gen-lint*
|
protoc-gen-lint *ale-proto-protoc-gen-lint*
|
||||||
|
|
||||||
@ -68,6 +80,7 @@ g:ale_proto_protoc_gen_lint_options *g:ale_proto_protoc_gen_lint_options*
|
|||||||
directory of the linted file is always passed as an include path with '-I'
|
directory of the linted file is always passed as an include path with '-I'
|
||||||
before any user-supplied options.
|
before any user-supplied options.
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
protolint *ale-proto-protolint*
|
protolint *ale-proto-protolint*
|
||||||
|
|
||||||
@ -80,7 +93,7 @@ protolint *ale-proto-protolint
|
|||||||
g:ale_proto_protolint_executable *g:ale_proto_protolint_executable*
|
g:ale_proto_protolint_executable *g:ale_proto_protolint_executable*
|
||||||
|
|
||||||
Type: |String|
|
Type: |String|
|
||||||
Default: 'protolint'
|
Default: `'protolint'`
|
||||||
|
|
||||||
This variable can be changed to modify the executable used for protolint.
|
This variable can be changed to modify the executable used for protolint.
|
||||||
|
|
||||||
@ -94,5 +107,6 @@ g:ale_proto_protolint_config *g:ale_proto_protolint_config*
|
|||||||
The path to the configuration file can be an absolute path or a relative
|
The path to the configuration file can be an absolute path or a relative
|
||||||
path. ALE will search for the relative path in parent directories.
|
path. ALE will search for the relative path in parent directories.
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
vim:tw=78:ts=2:sts=2:sw=2:ft=help:norl:
|
vim:tw=78:ts=2:sts=2:sw=2:ft=help:norl:
|
||||||
|
@ -48,7 +48,7 @@ g:ale_purescript_tidy_use_global *g:ale_purescript_tidy_use_global*
|
|||||||
|
|
||||||
g:ale_purescript_tidy_options *g:ale_purescript_tidy_options*
|
g:ale_purescript_tidy_options *g:ale_purescript_tidy_options*
|
||||||
*b:ale_purescript_tidy_options*
|
*b:ale_purescript_tidy_options*
|
||||||
Type: String
|
Type: |String|
|
||||||
Default: `''`
|
Default: `''`
|
||||||
|
|
||||||
This variable can be set to pass in additional option to the 'purs-tidy'
|
This variable can be set to pass in additional option to the 'purs-tidy'
|
||||||
|
@ -979,7 +979,7 @@ g:ale_python_pylsp_options *g:ale_python_pylsp_options
|
|||||||
let g:ale_python_pylsp_executable = 'python3'
|
let g:ale_python_pylsp_executable = 'python3'
|
||||||
let g:ale_python_pylsp_options = '-m pylsp'
|
let g:ale_python_pylsp_options = '-m pylsp'
|
||||||
|
|
||||||
An example stragety for installing `pylsp`:
|
An example strategy for installing `pylsp`:
|
||||||
`python3 -m pip install --user pylsp`
|
`python3 -m pip install --user pylsp`
|
||||||
|
|
||||||
|
|
||||||
@ -1115,6 +1115,69 @@ g:ale_python_reorder_python_imports_use_global
|
|||||||
See |ale-integrations-local-executables|
|
See |ale-integrations-local-executables|
|
||||||
|
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
ruff *ale-python-ruff*
|
||||||
|
|
||||||
|
g:ale_python_ruff_change_directory *g:ale_python_ruff_change_directory*
|
||||||
|
*b:ale_python_ruff_change_directory*
|
||||||
|
Type: |Number|
|
||||||
|
Default: `1`
|
||||||
|
|
||||||
|
If set to `1`, `ruff` will be run from a detected project root, per
|
||||||
|
|ale-python-root|. if set to `0` or no project root detected,
|
||||||
|
`ruff` will be run from the buffer's directory.
|
||||||
|
|
||||||
|
|
||||||
|
g:ale_python_ruff_executable *g:ale_python_ruff_executable*
|
||||||
|
*b:ale_python_ruff_executable*
|
||||||
|
Type: |String|
|
||||||
|
Default: `'ruff'`
|
||||||
|
|
||||||
|
See |ale-integrations-local-executables|
|
||||||
|
|
||||||
|
Set this to `'pipenv'` to invoke `'pipenv` `run` `ruff'`.
|
||||||
|
Set this to `'poetry'` to invoke `'poetry` `run` `ruff'`.
|
||||||
|
|
||||||
|
|
||||||
|
g:ale_python_ruff_options *g:ale_python_ruff_options*
|
||||||
|
*b:ale_python_ruff_options*
|
||||||
|
Type: |String|
|
||||||
|
Default: `''`
|
||||||
|
|
||||||
|
This variable can be changed to add command-line arguments to the ruff
|
||||||
|
invocation.
|
||||||
|
|
||||||
|
For example, to select/enable and/or disable some error codes,
|
||||||
|
you may want to set >
|
||||||
|
let g:ale_python_ruff_options = '--ignore F401'
|
||||||
|
|
||||||
|
|
||||||
|
g:ale_python_ruff_use_global *g:ale_python_ruff_use_global*
|
||||||
|
*b:ale_python_ruff_use_global*
|
||||||
|
Type: |Number|
|
||||||
|
Default: `get(g:, 'ale_use_global_executables', 0)`
|
||||||
|
|
||||||
|
See |ale-integrations-local-executables|
|
||||||
|
|
||||||
|
|
||||||
|
g:ale_python_ruff_auto_pipenv *g:ale_python_ruff_auto_pipenv*
|
||||||
|
*b:ale_python_ruff_auto_pipenv*
|
||||||
|
Type: |Number|
|
||||||
|
Default: `0`
|
||||||
|
|
||||||
|
Detect whether the file is inside a pipenv, and set the executable to `pipenv`
|
||||||
|
if true. This is overridden by a manually-set executable.
|
||||||
|
|
||||||
|
|
||||||
|
g:ale_python_ruff_auto_poetry *g:ale_python_ruff_auto_poetry*
|
||||||
|
*b:ale_python_ruff_auto_poetry*
|
||||||
|
Type: |Number|
|
||||||
|
Default: `0`
|
||||||
|
|
||||||
|
Detect whether the file is inside a poetry, and set the executable to `poetry`
|
||||||
|
if true. This is overridden by a manually-set executable.
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
unimport *ale-python-unimport*
|
unimport *ale-python-unimport*
|
||||||
|
|
||||||
|
@ -7,7 +7,7 @@ brakeman *ale-ruby-brakeman*
|
|||||||
|
|
||||||
g:ale_ruby_brakeman_executable *g:ale_ruby_brakeman_executable*
|
g:ale_ruby_brakeman_executable *g:ale_ruby_brakeman_executable*
|
||||||
*b:ale_ruby_brakeman_executable*
|
*b:ale_ruby_brakeman_executable*
|
||||||
Type: String
|
Type: |String|
|
||||||
Default: `'brakeman'`
|
Default: `'brakeman'`
|
||||||
|
|
||||||
Override the invoked brakeman binary. Set this to `'bundle'` to invoke
|
Override the invoked brakeman binary. Set this to `'bundle'` to invoke
|
||||||
@ -33,7 +33,7 @@ debride *ale-ruby-debride*
|
|||||||
|
|
||||||
g:ale_ruby_debride_executable *g:ale_ruby_debride_executable*
|
g:ale_ruby_debride_executable *g:ale_ruby_debride_executable*
|
||||||
*b:ale_ruby_debride_executable*
|
*b:ale_ruby_debride_executable*
|
||||||
Type: String
|
Type: |String|
|
||||||
Default: `'debride'`
|
Default: `'debride'`
|
||||||
|
|
||||||
Override the invoked debride binary. Set this to `'bundle'` to invoke
|
Override the invoked debride binary. Set this to `'bundle'` to invoke
|
||||||
@ -60,7 +60,7 @@ rails_best_practices *ale-ruby-rails_best_practices*
|
|||||||
g:ale_ruby_rails_best_practices_executable
|
g:ale_ruby_rails_best_practices_executable
|
||||||
*g:ale_ruby_rails_best_practices_executable*
|
*g:ale_ruby_rails_best_practices_executable*
|
||||||
*b:ale_ruby_rails_best_practices_executable*
|
*b:ale_ruby_rails_best_practices_executable*
|
||||||
Type: String
|
Type: |String|
|
||||||
Default: `'rails_best_practices'`
|
Default: `'rails_best_practices'`
|
||||||
|
|
||||||
Override the invoked rails_best_practices binary. Set this to `'bundle'` to
|
Override the invoked rails_best_practices binary. Set this to `'bundle'` to
|
||||||
@ -81,7 +81,7 @@ reek *ale-ruby-reek*
|
|||||||
|
|
||||||
g:ale_ruby_reek_executable *g:ale_ruby_reek_executable*
|
g:ale_ruby_reek_executable *g:ale_ruby_reek_executable*
|
||||||
*b:ale_ruby_reek_executable*
|
*b:ale_ruby_reek_executable*
|
||||||
Type: String
|
Type: |String|
|
||||||
Default: `'reek'`
|
Default: `'reek'`
|
||||||
|
|
||||||
Override the invoked reek binary. Set this to `'bundle'` to invoke
|
Override the invoked reek binary. Set this to `'bundle'` to invoke
|
||||||
@ -91,7 +91,7 @@ g:ale_ruby_reek_executable *g:ale_ruby_reek_executable*
|
|||||||
g:ale_ruby_reek_show_context *g:ale_ruby_reek_show_context*
|
g:ale_ruby_reek_show_context *g:ale_ruby_reek_show_context*
|
||||||
*b:ale_ruby_reek_show_context*
|
*b:ale_ruby_reek_show_context*
|
||||||
Type: |Number|
|
Type: |Number|
|
||||||
Default: 0
|
Default: `0`
|
||||||
|
|
||||||
Controls whether context is included in the linter message. Defaults to off
|
Controls whether context is included in the linter message. Defaults to off
|
||||||
because context is usually obvious while viewing a file.
|
because context is usually obvious while viewing a file.
|
||||||
@ -100,7 +100,7 @@ g:ale_ruby_reek_show_context *g:ale_ruby_reek_show_context*
|
|||||||
g:ale_ruby_reek_show_wiki_link *g:ale_ruby_reek_show_wiki_link*
|
g:ale_ruby_reek_show_wiki_link *g:ale_ruby_reek_show_wiki_link*
|
||||||
*b:ale_ruby_reek_show_wiki_link*
|
*b:ale_ruby_reek_show_wiki_link*
|
||||||
Type: |Number|
|
Type: |Number|
|
||||||
Default: 0
|
Default: `0`
|
||||||
|
|
||||||
Controls whether linter messages contain a link to an explanatory wiki page
|
Controls whether linter messages contain a link to an explanatory wiki page
|
||||||
for the type of code smell. Defaults to off to improve readability.
|
for the type of code smell. Defaults to off to improve readability.
|
||||||
@ -111,7 +111,7 @@ rubocop *ale-ruby-rubocop*
|
|||||||
|
|
||||||
g:ale_ruby_rubocop_executable *g:ale_ruby_rubocop_executable*
|
g:ale_ruby_rubocop_executable *g:ale_ruby_rubocop_executable*
|
||||||
*b:ale_ruby_rubocop_executable*
|
*b:ale_ruby_rubocop_executable*
|
||||||
Type: String
|
Type: |String|
|
||||||
Default: `'rubocop'`
|
Default: `'rubocop'`
|
||||||
|
|
||||||
Override the invoked rubocop binary. Set this to `'bundle'` to invoke
|
Override the invoked rubocop binary. Set this to `'bundle'` to invoke
|
||||||
@ -128,7 +128,7 @@ g:ale_ruby_rubocop_options *g:ale_ruby_rubocop_options*
|
|||||||
|
|
||||||
g:ale_ruby_rubocop_auto_correct_all *g:ale_ruby_rubocop_auto_correct_all*
|
g:ale_ruby_rubocop_auto_correct_all *g:ale_ruby_rubocop_auto_correct_all*
|
||||||
*b:ale_ruby_rubocop_auto_correct_all*
|
*b:ale_ruby_rubocop_auto_correct_all*
|
||||||
Type: Number
|
Type: |Number|
|
||||||
Default: `0`
|
Default: `0`
|
||||||
|
|
||||||
This variable can be changed to make rubocop to correct all offenses (unsafe).
|
This variable can be changed to make rubocop to correct all offenses (unsafe).
|
||||||
@ -139,7 +139,7 @@ ruby *ale-ruby-ruby*
|
|||||||
|
|
||||||
g:ale_ruby_ruby_executable *g:ale_ruby_ruby_executable*
|
g:ale_ruby_ruby_executable *g:ale_ruby_ruby_executable*
|
||||||
*b:ale_ruby_ruby_executable*
|
*b:ale_ruby_ruby_executable*
|
||||||
Type: String
|
Type: |String|
|
||||||
Default: `'ruby'`
|
Default: `'ruby'`
|
||||||
|
|
||||||
This variable can be changed to use a different executable for ruby.
|
This variable can be changed to use a different executable for ruby.
|
||||||
@ -150,7 +150,7 @@ rufo *ale-ruby-rufo*
|
|||||||
|
|
||||||
g:ale_ruby_rufo_executable *g:ale_ruby_rufo_executable*
|
g:ale_ruby_rufo_executable *g:ale_ruby_rufo_executable*
|
||||||
*b:ale_ruby_rufo_executable*
|
*b:ale_ruby_rufo_executable*
|
||||||
Type: String
|
Type: |String|
|
||||||
Default: `'rufo'`
|
Default: `'rufo'`
|
||||||
|
|
||||||
Override the invoked rufo binary. This is useful for running rufo from
|
Override the invoked rufo binary. This is useful for running rufo from
|
||||||
@ -162,7 +162,7 @@ solargraph *ale-ruby-solargraph*
|
|||||||
|
|
||||||
g:ale_ruby_solargraph_executable *g:ale_ruby_solargraph_executable*
|
g:ale_ruby_solargraph_executable *g:ale_ruby_solargraph_executable*
|
||||||
*b:ale_ruby_solargraph_executable*
|
*b:ale_ruby_solargraph_executable*
|
||||||
Type: String
|
Type: |String|
|
||||||
Default: `'solargraph'`
|
Default: `'solargraph'`
|
||||||
|
|
||||||
Override the invoked solargraph binary. This is useful for running solargraph
|
Override the invoked solargraph binary. This is useful for running solargraph
|
||||||
@ -174,7 +174,7 @@ sorbet *ale-ruby-sorbet*
|
|||||||
|
|
||||||
g:ale_ruby_sorbet_executable *g:ale_ruby_sorbet_executable*
|
g:ale_ruby_sorbet_executable *g:ale_ruby_sorbet_executable*
|
||||||
*b:ale_ruby_sorbet_executable*
|
*b:ale_ruby_sorbet_executable*
|
||||||
Type: String
|
Type: |String|
|
||||||
Default: `'srb'`
|
Default: `'srb'`
|
||||||
|
|
||||||
Override the invoked sorbet binary. Set this to `'bundle'` to invoke
|
Override the invoked sorbet binary. Set this to `'bundle'` to invoke
|
||||||
@ -204,7 +204,7 @@ standardrb *ale-ruby-standardrb*
|
|||||||
|
|
||||||
g:ale_ruby_standardrb_executable *g:ale_ruby_standardrb_executable*
|
g:ale_ruby_standardrb_executable *g:ale_ruby_standardrb_executable*
|
||||||
*b:ale_ruby_standardrb_executable*
|
*b:ale_ruby_standardrb_executable*
|
||||||
Type: String
|
Type: |String|
|
||||||
Default: `'standardrb'`
|
Default: `'standardrb'`
|
||||||
|
|
||||||
Override the invoked standardrb binary. Set this to `'bundle'` to invoke
|
Override the invoked standardrb binary. Set this to `'bundle'` to invoke
|
||||||
@ -224,7 +224,7 @@ syntax_tree *ale-ruby-syntax_tree*
|
|||||||
|
|
||||||
g:ale_ruby_syntax_tree_executable *g:ale_ruby_syntax_tree_executable*
|
g:ale_ruby_syntax_tree_executable *g:ale_ruby_syntax_tree_executable*
|
||||||
*b:ale_ruby_syntax_tree_executable*
|
*b:ale_ruby_syntax_tree_executable*
|
||||||
Type: String
|
Type: |String|
|
||||||
Default: `'stree'`
|
Default: `'stree'`
|
||||||
|
|
||||||
Override the invoked SyntaxTree binary. Set this to `'bundle'` to invoke
|
Override the invoked SyntaxTree binary. Set this to `'bundle'` to invoke
|
||||||
|
@ -261,8 +261,8 @@ g:ale_rust_ignore_error_codes *g:ale_rust_ignore_error_codes*
|
|||||||
|
|
||||||
g:ale_rust_ignore_secondary_spans *g:ale_rust_ignore_secondary_spans*
|
g:ale_rust_ignore_secondary_spans *g:ale_rust_ignore_secondary_spans*
|
||||||
*b:ale_rust_ignore_secondary_spans*
|
*b:ale_rust_ignore_secondary_spans*
|
||||||
Type: Number
|
Type: |Number|
|
||||||
Default: 0
|
Default: `0`
|
||||||
|
|
||||||
When set to 1, instructs the Rust error reporting to ignore secondary spans.
|
When set to 1, instructs the Rust error reporting to ignore secondary spans.
|
||||||
The problem with secondary spans is that they sometimes appear in error
|
The problem with secondary spans is that they sometimes appear in error
|
||||||
@ -288,5 +288,13 @@ g:ale_rust_rustfmt_options *g:ale_rust_rustfmt_options*
|
|||||||
This variable can be set to pass additional options to the rustfmt fixer.
|
This variable can be set to pass additional options to the rustfmt fixer.
|
||||||
|
|
||||||
|
|
||||||
|
g:ale_rust_rustfmt_executable *g:ale_rust_rustfmt_executable*
|
||||||
|
*b:ale_rust_rustfmt_executable*
|
||||||
|
Type: |String|
|
||||||
|
Default: `'rustfmt'`
|
||||||
|
|
||||||
|
This variable can be modified to change the executable path for `rustfmt`.
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
vim:tw=78:ts=2:sts=2:sw=2:ft=help:norl:
|
vim:tw=78:ts=2:sts=2:sw=2:ft=help:norl:
|
||||||
|
@ -27,6 +27,27 @@ g:ale_sql_pgformatter_options *g:ale_sql_pgformatter_options*
|
|||||||
This variable can be set to pass additional options to the pgformatter fixer.
|
This variable can be set to pass additional options to the pgformatter fixer.
|
||||||
|
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
sqlfluff *ale-sql-sqlfluff*
|
||||||
|
|
||||||
|
g:ale_sql_sqlfluff_executable *g:ale_sql_sqlfluff_executable*
|
||||||
|
*b:ale_sql_sqlfluff_executable*
|
||||||
|
Type: |String|
|
||||||
|
Default: `'sqlfluff'`
|
||||||
|
|
||||||
|
This variable sets executable used for sqlfluff.
|
||||||
|
|
||||||
|
g:ale_sql_sqlfluff_options *g:ale_sql_sqlfluff_options*
|
||||||
|
*b:ale_sql_sqlfluff_options*
|
||||||
|
Type: |String|
|
||||||
|
Default: `''`
|
||||||
|
|
||||||
|
This variable can be set to pass additional options to the sqlfluff linter.
|
||||||
|
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
sqlfmt *ale-sql-sqlfmt*
|
sqlfmt *ale-sql-sqlfmt*
|
||||||
|
|
||||||
|
@ -18,6 +18,7 @@ Notes:
|
|||||||
* `gcc`
|
* `gcc`
|
||||||
* `gnatpp`
|
* `gnatpp`
|
||||||
* Ansible
|
* Ansible
|
||||||
|
* `ansible-language-server`
|
||||||
* `ansible-lint`!!
|
* `ansible-lint`!!
|
||||||
* API Blueprint
|
* API Blueprint
|
||||||
* `drafter`
|
* `drafter`
|
||||||
@ -75,6 +76,7 @@ Notes:
|
|||||||
* `gcc` (`cc`)
|
* `gcc` (`cc`)
|
||||||
* `uncrustify`
|
* `uncrustify`
|
||||||
* C#
|
* C#
|
||||||
|
* `clang-format`
|
||||||
* `csc`!!
|
* `csc`!!
|
||||||
* `cspell`
|
* `cspell`
|
||||||
* `dotnet-format`
|
* `dotnet-format`
|
||||||
@ -128,6 +130,7 @@ Notes:
|
|||||||
* Cucumber
|
* Cucumber
|
||||||
* `cucumber`
|
* `cucumber`
|
||||||
* CUDA
|
* CUDA
|
||||||
|
* `clang-format`
|
||||||
* `clangd`
|
* `clangd`
|
||||||
* `nvcc`!!
|
* `nvcc`!!
|
||||||
* Cypher
|
* Cypher
|
||||||
@ -178,6 +181,7 @@ Notes:
|
|||||||
* `SyntaxErl`
|
* `SyntaxErl`
|
||||||
* `dialyzer`!!
|
* `dialyzer`!!
|
||||||
* `elvis`!!
|
* `elvis`!!
|
||||||
|
* `erlang_ls`
|
||||||
* `erlc`
|
* `erlc`
|
||||||
* `erlfmt`
|
* `erlfmt`
|
||||||
* Fish
|
* Fish
|
||||||
@ -269,6 +273,7 @@ Notes:
|
|||||||
* Java
|
* Java
|
||||||
* `PMD`
|
* `PMD`
|
||||||
* `checkstyle`!!
|
* `checkstyle`!!
|
||||||
|
* `clang-format`
|
||||||
* `cspell`
|
* `cspell`
|
||||||
* `eclipselsp`
|
* `eclipselsp`
|
||||||
* `google-java-format`
|
* `google-java-format`
|
||||||
@ -276,6 +281,7 @@ Notes:
|
|||||||
* `javalsp`
|
* `javalsp`
|
||||||
* `uncrustify`
|
* `uncrustify`
|
||||||
* JavaScript
|
* JavaScript
|
||||||
|
* `clang-format`
|
||||||
* `cspell`
|
* `cspell`
|
||||||
* `deno`
|
* `deno`
|
||||||
* `dprint`
|
* `dprint`
|
||||||
@ -292,6 +298,7 @@ Notes:
|
|||||||
* `xo`
|
* `xo`
|
||||||
* JSON
|
* JSON
|
||||||
* `VSCode JSON language server`
|
* `VSCode JSON language server`
|
||||||
|
* `clang-format`
|
||||||
* `cspell`
|
* `cspell`
|
||||||
* `dprint`
|
* `dprint`
|
||||||
* `eslint`
|
* `eslint`
|
||||||
@ -382,6 +389,7 @@ Notes:
|
|||||||
* Objective-C
|
* Objective-C
|
||||||
* `ccls`
|
* `ccls`
|
||||||
* `clang`
|
* `clang`
|
||||||
|
* `clang-format`
|
||||||
* `clangd`
|
* `clangd`
|
||||||
* `uncrustify`
|
* `uncrustify`
|
||||||
* Objective-C++
|
* Objective-C++
|
||||||
@ -448,6 +456,7 @@ Notes:
|
|||||||
* proto
|
* proto
|
||||||
* `buf-format`!!
|
* `buf-format`!!
|
||||||
* `buf-lint`!!
|
* `buf-lint`!!
|
||||||
|
* `clang-format`
|
||||||
* `protoc-gen-lint`!!
|
* `protoc-gen-lint`!!
|
||||||
* `protolint`!!
|
* `protolint`!!
|
||||||
* Pug
|
* Pug
|
||||||
@ -482,6 +491,7 @@ Notes:
|
|||||||
* `pyre`
|
* `pyre`
|
||||||
* `pyright`
|
* `pyright`
|
||||||
* `reorder-python-imports`
|
* `reorder-python-imports`
|
||||||
|
* ruff
|
||||||
* `unimport`
|
* `unimport`
|
||||||
* `vulture`!!
|
* `vulture`!!
|
||||||
* `yapf`
|
* `yapf`
|
||||||
@ -495,6 +505,7 @@ Notes:
|
|||||||
* Racket
|
* Racket
|
||||||
* `racket-langserver`
|
* `racket-langserver`
|
||||||
* `raco`
|
* `raco`
|
||||||
|
* `raco_fmt`
|
||||||
* Re:VIEW
|
* Re:VIEW
|
||||||
* `redpen`
|
* `redpen`
|
||||||
* ReasonML
|
* ReasonML
|
||||||
@ -570,6 +581,7 @@ Notes:
|
|||||||
* `dprint`
|
* `dprint`
|
||||||
* `pgformatter`
|
* `pgformatter`
|
||||||
* `sql-lint`
|
* `sql-lint`
|
||||||
|
* `sqlfluff`
|
||||||
* `sqlfmt`
|
* `sqlfmt`
|
||||||
* `sqlformat`
|
* `sqlformat`
|
||||||
* `sqlint`
|
* `sqlint`
|
||||||
|
@ -33,7 +33,7 @@ lacheck *ale-tex-lacheck*
|
|||||||
g:ale_lacheck_executable *g:ale_lacheck_executable*
|
g:ale_lacheck_executable *g:ale_lacheck_executable*
|
||||||
*b:ale_lacheck_executable*
|
*b:ale_lacheck_executable*
|
||||||
Type: |String|
|
Type: |String|
|
||||||
Default: '`lacheck`'
|
Default: `'lacheck'`
|
||||||
|
|
||||||
This variable can be changed to change the path to lacheck.
|
This variable can be changed to change the path to lacheck.
|
||||||
|
|
||||||
|
@ -29,7 +29,7 @@ g:ale_deno_lsp_project_root *g:ale_deno_lsp_project_root*
|
|||||||
executing the following steps in the given order:
|
executing the following steps in the given order:
|
||||||
|
|
||||||
1. Find an ancestor directory containing a tsconfig.json.
|
1. Find an ancestor directory containing a tsconfig.json.
|
||||||
2. Find an ancestory directory containing a .git folder.
|
2. Find an ancestor directory containing a .git folder.
|
||||||
3. Use the directory of the current buffer (if the buffer was opened from
|
3. Use the directory of the current buffer (if the buffer was opened from
|
||||||
a file).
|
a file).
|
||||||
|
|
||||||
|
@ -134,7 +134,7 @@ g:ale_verilog_yosys_options *g:ale_verilog_yosys_options*
|
|||||||
Default: `'-Q -T -p ''read_verilog %s'''`
|
Default: `'-Q -T -p ''read_verilog %s'''`
|
||||||
|
|
||||||
This variable can be changed to modify the flags/options passed to 'yosys'.
|
This variable can be changed to modify the flags/options passed to 'yosys'.
|
||||||
By default, Yosys is an interative program. To obtain linting functionality,
|
By default, Yosys is an interactive program. To obtain linting functionality,
|
||||||
the `'read_verilog'` command is used.
|
the `'read_verilog'` command is used.
|
||||||
|
|
||||||
|
|
||||||
|
@ -24,7 +24,7 @@ g:ale_xml_xmllint_options *g:ale_xml_xmllint_options*
|
|||||||
g:ale_xml_xmllint_indentsize *g:ale_xml_xmllint_indentsize*
|
g:ale_xml_xmllint_indentsize *g:ale_xml_xmllint_indentsize*
|
||||||
*b:ale_xml_xmllint_indentsize*
|
*b:ale_xml_xmllint_indentsize*
|
||||||
Type: |Number|
|
Type: |Number|
|
||||||
Default: 2
|
Default: `2`
|
||||||
|
|
||||||
This variable can be sent to specify the amount of spaces used for
|
This variable can be sent to specify the amount of spaces used for
|
||||||
indentation.
|
indentation.
|
||||||
|
@ -750,7 +750,7 @@ g:airline#extensions#ale#enabled *g:airline#extensions#ale#enabled*
|
|||||||
g:ale_cache_executable_check_failures *g:ale_cache_executable_check_failures*
|
g:ale_cache_executable_check_failures *g:ale_cache_executable_check_failures*
|
||||||
|
|
||||||
Type: |Number|
|
Type: |Number|
|
||||||
Default: undefined
|
Default: not set
|
||||||
|
|
||||||
When set to `1`, ALE will cache failing executable checks for linters. By
|
When set to `1`, ALE will cache failing executable checks for linters. By
|
||||||
default, only executable checks which succeed will be cached.
|
default, only executable checks which succeed will be cached.
|
||||||
@ -864,7 +864,7 @@ g:ale_completion_enabled *g:ale_completion_enabled*
|
|||||||
*g:ale_completion_tsserver_remove_warnings*
|
*g:ale_completion_tsserver_remove_warnings*
|
||||||
g:ale_completion_tsserver_remove_warnings
|
g:ale_completion_tsserver_remove_warnings
|
||||||
|
|
||||||
Type: Number
|
Type: |Number|
|
||||||
Default: `0`
|
Default: `0`
|
||||||
|
|
||||||
When this option is set to `0`, ALE will return all completion items,
|
When this option is set to `0`, ALE will return all completion items,
|
||||||
@ -874,7 +874,7 @@ g:ale_completion_tsserver_remove_warnings
|
|||||||
|
|
||||||
g:ale_completion_autoimport *g:ale_completion_autoimport*
|
g:ale_completion_autoimport *g:ale_completion_autoimport*
|
||||||
|
|
||||||
Type: Number
|
Type: |Number|
|
||||||
Default: `1`
|
Default: `1`
|
||||||
|
|
||||||
When this option is set to `1`, ALE will try to automatically import
|
When this option is set to `1`, ALE will try to automatically import
|
||||||
@ -1836,7 +1836,7 @@ g:ale_max_signs *g:ale_max_signs*
|
|||||||
g:ale_maximum_file_size *g:ale_maximum_file_size*
|
g:ale_maximum_file_size *g:ale_maximum_file_size*
|
||||||
*b:ale_maximum_file_size*
|
*b:ale_maximum_file_size*
|
||||||
Type: |Number|
|
Type: |Number|
|
||||||
Default: undefined
|
Default: not set
|
||||||
|
|
||||||
A maximum file size in bytes for ALE to check. If set to any positive
|
A maximum file size in bytes for ALE to check. If set to any positive
|
||||||
number, ALE will skip checking files larger than the given size.
|
number, ALE will skip checking files larger than the given size.
|
||||||
@ -1879,7 +1879,7 @@ g:ale_open_list *g:ale_open_list*
|
|||||||
g:ale_pattern_options *g:ale_pattern_options*
|
g:ale_pattern_options *g:ale_pattern_options*
|
||||||
|
|
||||||
Type: |Dictionary|
|
Type: |Dictionary|
|
||||||
Default: undefined
|
Default: not set
|
||||||
|
|
||||||
This option maps regular expression patterns to |Dictionary| values for
|
This option maps regular expression patterns to |Dictionary| values for
|
||||||
buffer variables. This option can be set to automatically configure
|
buffer variables. This option can be set to automatically configure
|
||||||
@ -1908,7 +1908,7 @@ g:ale_pattern_options *g:ale_pattern_options*
|
|||||||
g:ale_pattern_options_enabled *g:ale_pattern_options_enabled*
|
g:ale_pattern_options_enabled *g:ale_pattern_options_enabled*
|
||||||
|
|
||||||
Type: |Number|
|
Type: |Number|
|
||||||
Default: undefined
|
Default: not set
|
||||||
|
|
||||||
This option can be used for disabling pattern options. If set to `0`, ALE
|
This option can be used for disabling pattern options. If set to `0`, ALE
|
||||||
will not set buffer variables per |g:ale_pattern_options|.
|
will not set buffer variables per |g:ale_pattern_options|.
|
||||||
@ -1954,7 +1954,7 @@ g:ale_root *g:ale_root*
|
|||||||
*b:ale_root*
|
*b:ale_root*
|
||||||
|
|
||||||
Type: |Dictionary| or |String|
|
Type: |Dictionary| or |String|
|
||||||
Default: {}
|
Default: `{}`
|
||||||
|
|
||||||
This option is used to determine the project root for a linter. If the value
|
This option is used to determine the project root for a linter. If the value
|
||||||
is a |Dictionary|, it maps a linter to either a |String| containing the
|
is a |Dictionary|, it maps a linter to either a |String| containing the
|
||||||
@ -2006,7 +2006,7 @@ g:ale_set_balloons *g:ale_set_balloons*
|
|||||||
g:ale_set_balloons_legacy_echo *g:ale_set_balloons_legacy_echo*
|
g:ale_set_balloons_legacy_echo *g:ale_set_balloons_legacy_echo*
|
||||||
*b:ale_set_balloons_legacy_echo*
|
*b:ale_set_balloons_legacy_echo*
|
||||||
Type: |Number|
|
Type: |Number|
|
||||||
Default: undefined
|
Default: not set
|
||||||
|
|
||||||
If set to `1`, moving your mouse over documents in Vim will make ALE ask
|
If set to `1`, moving your mouse over documents in Vim will make ALE ask
|
||||||
`tsserver` or `LSP` servers for information about the symbol where the mouse
|
`tsserver` or `LSP` servers for information about the symbol where the mouse
|
||||||
@ -2240,10 +2240,10 @@ g:ale_sign_highlight_linenrs *g:ale_sign_highlight_linenrs*
|
|||||||
|
|
||||||
g:ale_update_tagstack *g:ale_update_tagstack*
|
g:ale_update_tagstack *g:ale_update_tagstack*
|
||||||
*b:ale_update_tagstack*
|
*b:ale_update_tagstack*
|
||||||
Type: |Number|
|
Type: |Number|
|
||||||
Default: `1`
|
Default: `1`
|
||||||
|
|
||||||
This option can be set to disable updating Vim's |tagstack| automatically.
|
This option can be set to disable updating Vim's |tagstack| automatically.
|
||||||
|
|
||||||
|
|
||||||
g:ale_type_map *g:ale_type_map*
|
g:ale_type_map *g:ale_type_map*
|
||||||
@ -2767,6 +2767,7 @@ documented in additional help files.
|
|||||||
gnatpp................................|ale-ada-gnatpp|
|
gnatpp................................|ale-ada-gnatpp|
|
||||||
ada-language-server...................|ale-ada-language-server|
|
ada-language-server...................|ale-ada-language-server|
|
||||||
ansible.................................|ale-ansible-options|
|
ansible.................................|ale-ansible-options|
|
||||||
|
ansible-language-server...............|ale-ansible-language-server|
|
||||||
ansible-lint..........................|ale-ansible-ansible-lint|
|
ansible-lint..........................|ale-ansible-ansible-lint|
|
||||||
apkbuild................................|ale-apkbuild-options|
|
apkbuild................................|ale-apkbuild-options|
|
||||||
apkbuild-lint.........................|ale-apkbuild-apkbuild-lint|
|
apkbuild-lint.........................|ale-apkbuild-apkbuild-lint|
|
||||||
@ -2833,6 +2834,7 @@ documented in additional help files.
|
|||||||
flawfinder............................|ale-cpp-flawfinder|
|
flawfinder............................|ale-cpp-flawfinder|
|
||||||
uncrustify............................|ale-cpp-uncrustify|
|
uncrustify............................|ale-cpp-uncrustify|
|
||||||
c#......................................|ale-cs-options|
|
c#......................................|ale-cs-options|
|
||||||
|
clang-format..........................|ale-cs-clangformat|
|
||||||
csc...................................|ale-cs-csc|
|
csc...................................|ale-cs-csc|
|
||||||
cspell................................|ale-cs-cspell|
|
cspell................................|ale-cs-cspell|
|
||||||
dotnet-format.........................|ale-cs-dotnet-format|
|
dotnet-format.........................|ale-cs-dotnet-format|
|
||||||
@ -2847,9 +2849,9 @@ documented in additional help files.
|
|||||||
stylelint.............................|ale-css-stylelint|
|
stylelint.............................|ale-css-stylelint|
|
||||||
vscodecss.............................|ale-css-vscode|
|
vscodecss.............................|ale-css-vscode|
|
||||||
cuda....................................|ale-cuda-options|
|
cuda....................................|ale-cuda-options|
|
||||||
nvcc..................................|ale-cuda-nvcc|
|
|
||||||
clangd................................|ale-cuda-clangd|
|
|
||||||
clang-format..........................|ale-cuda-clangformat|
|
clang-format..........................|ale-cuda-clangformat|
|
||||||
|
clangd................................|ale-cuda-clangd|
|
||||||
|
nvcc..................................|ale-cuda-nvcc|
|
||||||
d.......................................|ale-d-options|
|
d.......................................|ale-d-options|
|
||||||
dfmt..................................|ale-d-dfmt|
|
dfmt..................................|ale-d-dfmt|
|
||||||
dls...................................|ale-d-dls|
|
dls...................................|ale-d-dls|
|
||||||
@ -2885,6 +2887,7 @@ documented in additional help files.
|
|||||||
erlang..................................|ale-erlang-options|
|
erlang..................................|ale-erlang-options|
|
||||||
dialyzer..............................|ale-erlang-dialyzer|
|
dialyzer..............................|ale-erlang-dialyzer|
|
||||||
elvis.................................|ale-erlang-elvis|
|
elvis.................................|ale-erlang-elvis|
|
||||||
|
erlang_ls.............................|ale-erlang-erlang_ls|
|
||||||
erlc..................................|ale-erlang-erlc|
|
erlc..................................|ale-erlang-erlc|
|
||||||
erlfmt................................|ale-erlang-erlfmt|
|
erlfmt................................|ale-erlang-erlfmt|
|
||||||
syntaxerl.............................|ale-erlang-syntaxerl|
|
syntaxerl.............................|ale-erlang-syntaxerl|
|
||||||
@ -2973,6 +2976,7 @@ documented in additional help files.
|
|||||||
ispc..................................|ale-ispc-ispc|
|
ispc..................................|ale-ispc-ispc|
|
||||||
java....................................|ale-java-options|
|
java....................................|ale-java-options|
|
||||||
checkstyle............................|ale-java-checkstyle|
|
checkstyle............................|ale-java-checkstyle|
|
||||||
|
clang-format..........................|ale-java-clangformat|
|
||||||
cspell................................|ale-java-cspell|
|
cspell................................|ale-java-cspell|
|
||||||
javac.................................|ale-java-javac|
|
javac.................................|ale-java-javac|
|
||||||
google-java-format....................|ale-java-google-java-format|
|
google-java-format....................|ale-java-google-java-format|
|
||||||
@ -2981,6 +2985,7 @@ documented in additional help files.
|
|||||||
eclipselsp............................|ale-java-eclipselsp|
|
eclipselsp............................|ale-java-eclipselsp|
|
||||||
uncrustify............................|ale-java-uncrustify|
|
uncrustify............................|ale-java-uncrustify|
|
||||||
javascript..............................|ale-javascript-options|
|
javascript..............................|ale-javascript-options|
|
||||||
|
clang-format..........................|ale-javascript-clangformat|
|
||||||
cspell................................|ale-javascript-cspell|
|
cspell................................|ale-javascript-cspell|
|
||||||
deno..................................|ale-javascript-deno|
|
deno..................................|ale-javascript-deno|
|
||||||
dprint................................|ale-javascript-dprint|
|
dprint................................|ale-javascript-dprint|
|
||||||
@ -2996,6 +3001,7 @@ documented in additional help files.
|
|||||||
standard..............................|ale-javascript-standard|
|
standard..............................|ale-javascript-standard|
|
||||||
xo....................................|ale-javascript-xo|
|
xo....................................|ale-javascript-xo|
|
||||||
json....................................|ale-json-options|
|
json....................................|ale-json-options|
|
||||||
|
clang-format..........................|ale-json-clangformat|
|
||||||
cspell................................|ale-json-cspell|
|
cspell................................|ale-json-cspell|
|
||||||
dprint................................|ale-json-dprint|
|
dprint................................|ale-json-dprint|
|
||||||
eslint................................|ale-json-eslint|
|
eslint................................|ale-json-eslint|
|
||||||
@ -3036,6 +3042,8 @@ documented in additional help files.
|
|||||||
luafmt................................|ale-lua-luafmt|
|
luafmt................................|ale-lua-luafmt|
|
||||||
selene................................|ale-lua-selene|
|
selene................................|ale-lua-selene|
|
||||||
stylua................................|ale-lua-stylua|
|
stylua................................|ale-lua-stylua|
|
||||||
|
make....................................|ale-make-options|
|
||||||
|
checkmake.............................|ale-make-checkmake|
|
||||||
markdown................................|ale-markdown-options|
|
markdown................................|ale-markdown-options|
|
||||||
cspell................................|ale-markdown-cspell|
|
cspell................................|ale-markdown-cspell|
|
||||||
dprint................................|ale-markdown-dprint|
|
dprint................................|ale-markdown-dprint|
|
||||||
@ -3061,10 +3069,11 @@ documented in additional help files.
|
|||||||
nroff...................................|ale-nroff-options|
|
nroff...................................|ale-nroff-options|
|
||||||
write-good............................|ale-nroff-write-good|
|
write-good............................|ale-nroff-write-good|
|
||||||
objc....................................|ale-objc-options|
|
objc....................................|ale-objc-options|
|
||||||
|
ccls..................................|ale-objc-ccls|
|
||||||
clang.................................|ale-objc-clang|
|
clang.................................|ale-objc-clang|
|
||||||
|
clang-format..........................|ale-objc-clangformat|
|
||||||
clangd................................|ale-objc-clangd|
|
clangd................................|ale-objc-clangd|
|
||||||
uncrustify............................|ale-objc-uncrustify|
|
uncrustify............................|ale-objc-uncrustify|
|
||||||
ccls..................................|ale-objc-ccls|
|
|
||||||
objcpp..................................|ale-objcpp-options|
|
objcpp..................................|ale-objcpp-options|
|
||||||
clang.................................|ale-objcpp-clang|
|
clang.................................|ale-objcpp-clang|
|
||||||
clangd................................|ale-objcpp-clangd|
|
clangd................................|ale-objcpp-clangd|
|
||||||
@ -3123,6 +3132,7 @@ documented in additional help files.
|
|||||||
proto...................................|ale-proto-options|
|
proto...................................|ale-proto-options|
|
||||||
buf-format............................|ale-proto-buf-format|
|
buf-format............................|ale-proto-buf-format|
|
||||||
buf-lint..............................|ale-proto-buf-lint|
|
buf-lint..............................|ale-proto-buf-lint|
|
||||||
|
clang-format..........................|ale-proto-clangformat|
|
||||||
protoc-gen-lint.......................|ale-proto-protoc-gen-lint|
|
protoc-gen-lint.......................|ale-proto-protoc-gen-lint|
|
||||||
protolint.............................|ale-proto-protolint|
|
protolint.............................|ale-proto-protolint|
|
||||||
pug.....................................|ale-pug-options|
|
pug.....................................|ale-pug-options|
|
||||||
@ -3159,6 +3169,7 @@ documented in additional help files.
|
|||||||
pyre..................................|ale-python-pyre|
|
pyre..................................|ale-python-pyre|
|
||||||
pyright...............................|ale-python-pyright|
|
pyright...............................|ale-python-pyright|
|
||||||
reorder-python-imports................|ale-python-reorder_python_imports|
|
reorder-python-imports................|ale-python-reorder_python_imports|
|
||||||
|
ruff..................................|ale-python-ruff|
|
||||||
unimport..............................|ale-python-unimport|
|
unimport..............................|ale-python-unimport|
|
||||||
vulture...............................|ale-python-vulture|
|
vulture...............................|ale-python-vulture|
|
||||||
yapf..................................|ale-python-yapf|
|
yapf..................................|ale-python-yapf|
|
||||||
@ -3237,6 +3248,7 @@ documented in additional help files.
|
|||||||
sql.....................................|ale-sql-options|
|
sql.....................................|ale-sql-options|
|
||||||
dprint................................|ale-sql-dprint|
|
dprint................................|ale-sql-dprint|
|
||||||
pgformatter...........................|ale-sql-pgformatter|
|
pgformatter...........................|ale-sql-pgformatter|
|
||||||
|
sqlfluff..............................|ale-sql-sqlfluff|
|
||||||
sqlfmt................................|ale-sql-sqlfmt|
|
sqlfmt................................|ale-sql-sqlfmt|
|
||||||
sqlformat.............................|ale-sql-sqlformat|
|
sqlformat.............................|ale-sql-sqlformat|
|
||||||
stylus..................................|ale-stylus-options|
|
stylus..................................|ale-stylus-options|
|
||||||
@ -4558,7 +4570,7 @@ ALEFixPost *ALEFixPost-autocmd*
|
|||||||
These |User| autocommands are triggered before and after every lint or fix
|
These |User| autocommands are triggered before and after every lint or fix
|
||||||
cycle. They can be used to update statuslines, send notifications, etc.
|
cycle. They can be used to update statuslines, send notifications, etc.
|
||||||
The autocmd commands are run with |:silent|, so |:unsilent| is required for
|
The autocmd commands are run with |:silent|, so |:unsilent| is required for
|
||||||
echoing messges.
|
echoing messages.
|
||||||
|
|
||||||
For example to change the color of the statusline while the linter is
|
For example to change the color of the statusline while the linter is
|
||||||
running:
|
running:
|
||||||
@ -4591,7 +4603,7 @@ ALEJobStarted *ALEJobStarted-autocmd*
|
|||||||
ALELSPStarted *ALELSPStarted-autocmd*
|
ALELSPStarted *ALELSPStarted-autocmd*
|
||||||
*ALELSPStarted*
|
*ALELSPStarted*
|
||||||
|
|
||||||
This |User| autocommand is trigged immediately after an LSP connection is
|
This |User| autocommand is triggered immediately after an LSP connection is
|
||||||
successfully initialized. This provides a way to perform any additional
|
successfully initialized. This provides a way to perform any additional
|
||||||
initialization work, such as setting up buffer-level mappings.
|
initialization work, such as setting up buffer-level mappings.
|
||||||
|
|
||||||
|
@ -323,6 +323,7 @@ nnoremap <silent> <Plug>(ale_go_to_type_definition) :ALEGoToTypeDefinition<Retur
|
|||||||
nnoremap <silent> <Plug>(ale_go_to_type_definition_in_tab) :ALEGoToTypeDefinition -tab<Return>
|
nnoremap <silent> <Plug>(ale_go_to_type_definition_in_tab) :ALEGoToTypeDefinition -tab<Return>
|
||||||
nnoremap <silent> <Plug>(ale_go_to_type_definition_in_split) :ALEGoToTypeDefinition -split<Return>
|
nnoremap <silent> <Plug>(ale_go_to_type_definition_in_split) :ALEGoToTypeDefinition -split<Return>
|
||||||
nnoremap <silent> <Plug>(ale_go_to_type_definition_in_vsplit) :ALEGoToTypeDefinition -vsplit<Return>
|
nnoremap <silent> <Plug>(ale_go_to_type_definition_in_vsplit) :ALEGoToTypeDefinition -vsplit<Return>
|
||||||
|
nnoremap <silent> <Plug>(ale_go_to_implementation) :ALEGoToImplementation<Return>
|
||||||
nnoremap <silent> <Plug>(ale_go_to_implementation_in_tab) :ALEGoToImplementation -tab<Return>
|
nnoremap <silent> <Plug>(ale_go_to_implementation_in_tab) :ALEGoToImplementation -tab<Return>
|
||||||
nnoremap <silent> <Plug>(ale_go_to_implementation_in_split) :ALEGoToImplementation -split<Return>
|
nnoremap <silent> <Plug>(ale_go_to_implementation_in_split) :ALEGoToImplementation -split<Return>
|
||||||
nnoremap <silent> <Plug>(ale_go_to_implementation_in_vsplit) :ALEGoToImplementation -vsplit<Return>
|
nnoremap <silent> <Plug>(ale_go_to_implementation_in_vsplit) :ALEGoToImplementation -vsplit<Return>
|
||||||
|
@ -27,6 +27,7 @@ formatting.
|
|||||||
* [gcc](https://gcc.gnu.org)
|
* [gcc](https://gcc.gnu.org)
|
||||||
* [gnatpp](https://docs.adacore.com/gnat_ugn-docs/html/gnat_ugn/gnat_ugn/gnat_utility_programs.html#the-gnat-pretty-printer-gnatpp) :floppy_disk:
|
* [gnatpp](https://docs.adacore.com/gnat_ugn-docs/html/gnat_ugn/gnat_ugn/gnat_utility_programs.html#the-gnat-pretty-printer-gnatpp) :floppy_disk:
|
||||||
* Ansible
|
* Ansible
|
||||||
|
* [ansible-language-server](https://github.com/ansible/ansible-language-server/)
|
||||||
* [ansible-lint](https://github.com/willthames/ansible-lint) :floppy_disk:
|
* [ansible-lint](https://github.com/willthames/ansible-lint) :floppy_disk:
|
||||||
* API Blueprint
|
* API Blueprint
|
||||||
* [drafter](https://github.com/apiaryio/drafter)
|
* [drafter](https://github.com/apiaryio/drafter)
|
||||||
@ -84,6 +85,7 @@ formatting.
|
|||||||
* [gcc](https://gcc.gnu.org/)
|
* [gcc](https://gcc.gnu.org/)
|
||||||
* [uncrustify](https://github.com/uncrustify/uncrustify)
|
* [uncrustify](https://github.com/uncrustify/uncrustify)
|
||||||
* C#
|
* C#
|
||||||
|
* [clang-format](https://clang.llvm.org/docs/ClangFormat.html)
|
||||||
* [csc](http://www.mono-project.com/docs/about-mono/languages/csharp/) :floppy_disk: see:`help ale-cs-csc` for details and configuration
|
* [csc](http://www.mono-project.com/docs/about-mono/languages/csharp/) :floppy_disk: see:`help ale-cs-csc` for details and configuration
|
||||||
* [cspell](https://github.com/streetsidesoftware/cspell/tree/main/packages/cspell)
|
* [cspell](https://github.com/streetsidesoftware/cspell/tree/main/packages/cspell)
|
||||||
* [dotnet-format](https://github.com/dotnet/format)
|
* [dotnet-format](https://github.com/dotnet/format)
|
||||||
@ -137,6 +139,7 @@ formatting.
|
|||||||
* Cucumber
|
* Cucumber
|
||||||
* [cucumber](https://cucumber.io/)
|
* [cucumber](https://cucumber.io/)
|
||||||
* CUDA
|
* CUDA
|
||||||
|
* [clang-format](https://clang.llvm.org/docs/ClangFormat.html)
|
||||||
* [clangd](https://clang.llvm.org/extra/clangd.html)
|
* [clangd](https://clang.llvm.org/extra/clangd.html)
|
||||||
* [nvcc](http://docs.nvidia.com/cuda/cuda-compiler-driver-nvcc/index.html) :floppy_disk:
|
* [nvcc](http://docs.nvidia.com/cuda/cuda-compiler-driver-nvcc/index.html) :floppy_disk:
|
||||||
* Cypher
|
* Cypher
|
||||||
@ -187,6 +190,7 @@ formatting.
|
|||||||
* [SyntaxErl](https://github.com/ten0s/syntaxerl)
|
* [SyntaxErl](https://github.com/ten0s/syntaxerl)
|
||||||
* [dialyzer](http://erlang.org/doc/man/dialyzer.html) :floppy_disk:
|
* [dialyzer](http://erlang.org/doc/man/dialyzer.html) :floppy_disk:
|
||||||
* [elvis](https://github.com/inaka/elvis) :floppy_disk:
|
* [elvis](https://github.com/inaka/elvis) :floppy_disk:
|
||||||
|
* [erlang_ls](https://github.com/erlang-ls/erlang_ls)
|
||||||
* [erlc](http://erlang.org/doc/man/erlc.html)
|
* [erlc](http://erlang.org/doc/man/erlc.html)
|
||||||
* [erlfmt](https://github.com/WhatsApp/erlfmt)
|
* [erlfmt](https://github.com/WhatsApp/erlfmt)
|
||||||
* Fish
|
* Fish
|
||||||
@ -278,6 +282,7 @@ formatting.
|
|||||||
* Java
|
* Java
|
||||||
* [PMD](https://pmd.github.io/)
|
* [PMD](https://pmd.github.io/)
|
||||||
* [checkstyle](http://checkstyle.sourceforge.net) :floppy_disk:
|
* [checkstyle](http://checkstyle.sourceforge.net) :floppy_disk:
|
||||||
|
* [clang-format](https://clang.llvm.org/docs/ClangFormat.html)
|
||||||
* [cspell](https://github.com/streetsidesoftware/cspell/tree/main/packages/cspell)
|
* [cspell](https://github.com/streetsidesoftware/cspell/tree/main/packages/cspell)
|
||||||
* [eclipselsp](https://github.com/eclipse/eclipse.jdt.ls)
|
* [eclipselsp](https://github.com/eclipse/eclipse.jdt.ls)
|
||||||
* [google-java-format](https://github.com/google/google-java-format)
|
* [google-java-format](https://github.com/google/google-java-format)
|
||||||
@ -285,6 +290,7 @@ formatting.
|
|||||||
* [javalsp](https://github.com/georgewfraser/vscode-javac)
|
* [javalsp](https://github.com/georgewfraser/vscode-javac)
|
||||||
* [uncrustify](https://github.com/uncrustify/uncrustify)
|
* [uncrustify](https://github.com/uncrustify/uncrustify)
|
||||||
* JavaScript
|
* JavaScript
|
||||||
|
* [clang-format](https://clang.llvm.org/docs/ClangFormat.html)
|
||||||
* [cspell](https://github.com/streetsidesoftware/cspell/tree/main/packages/cspell)
|
* [cspell](https://github.com/streetsidesoftware/cspell/tree/main/packages/cspell)
|
||||||
* [deno](https://deno.land/)
|
* [deno](https://deno.land/)
|
||||||
* [dprint](https://dprint.dev/)
|
* [dprint](https://dprint.dev/)
|
||||||
@ -301,6 +307,7 @@ formatting.
|
|||||||
* [xo](https://github.com/sindresorhus/xo)
|
* [xo](https://github.com/sindresorhus/xo)
|
||||||
* JSON
|
* JSON
|
||||||
* [VSCode JSON language server](https://github.com/hrsh7th/vscode-langservers-extracted)
|
* [VSCode JSON language server](https://github.com/hrsh7th/vscode-langservers-extracted)
|
||||||
|
* [clang-format](https://clang.llvm.org/docs/ClangFormat.html)
|
||||||
* [cspell](https://github.com/streetsidesoftware/cspell/tree/main/packages/cspell) :warning:
|
* [cspell](https://github.com/streetsidesoftware/cspell/tree/main/packages/cspell) :warning:
|
||||||
* [dprint](https://dprint.dev)
|
* [dprint](https://dprint.dev)
|
||||||
* [eslint](http://eslint.org/) :warning:
|
* [eslint](http://eslint.org/) :warning:
|
||||||
@ -391,6 +398,7 @@ formatting.
|
|||||||
* Objective-C
|
* Objective-C
|
||||||
* [ccls](https://github.com/MaskRay/ccls)
|
* [ccls](https://github.com/MaskRay/ccls)
|
||||||
* [clang](http://clang.llvm.org/)
|
* [clang](http://clang.llvm.org/)
|
||||||
|
* [clang-format](https://clang.llvm.org/docs/ClangFormat.html)
|
||||||
* [clangd](https://clang.llvm.org/extra/clangd.html)
|
* [clangd](https://clang.llvm.org/extra/clangd.html)
|
||||||
* [uncrustify](https://github.com/uncrustify/uncrustify)
|
* [uncrustify](https://github.com/uncrustify/uncrustify)
|
||||||
* Objective-C++
|
* Objective-C++
|
||||||
@ -457,6 +465,7 @@ formatting.
|
|||||||
* proto
|
* proto
|
||||||
* [buf-format](https://github.com/bufbuild/buf) :floppy_disk:
|
* [buf-format](https://github.com/bufbuild/buf) :floppy_disk:
|
||||||
* [buf-lint](https://github.com/bufbuild/buf) :floppy_disk:
|
* [buf-lint](https://github.com/bufbuild/buf) :floppy_disk:
|
||||||
|
* [clang-format](https://clang.llvm.org/docs/ClangFormat.html)
|
||||||
* [protoc-gen-lint](https://github.com/ckaznocha/protoc-gen-lint) :floppy_disk:
|
* [protoc-gen-lint](https://github.com/ckaznocha/protoc-gen-lint) :floppy_disk:
|
||||||
* [protolint](https://github.com/yoheimuta/protolint) :floppy_disk:
|
* [protolint](https://github.com/yoheimuta/protolint) :floppy_disk:
|
||||||
* Pug
|
* Pug
|
||||||
@ -491,6 +500,7 @@ formatting.
|
|||||||
* [pyre](https://github.com/facebook/pyre-check) :warning:
|
* [pyre](https://github.com/facebook/pyre-check) :warning:
|
||||||
* [pyright](https://github.com/microsoft/pyright)
|
* [pyright](https://github.com/microsoft/pyright)
|
||||||
* [reorder-python-imports](https://github.com/asottile/reorder_python_imports)
|
* [reorder-python-imports](https://github.com/asottile/reorder_python_imports)
|
||||||
|
* [ruff](https://github.com/charliermarsh/ruff)
|
||||||
* [unimport](https://github.com/hakancelik96/unimport)
|
* [unimport](https://github.com/hakancelik96/unimport)
|
||||||
* [vulture](https://github.com/jendrikseipp/vulture) :warning: :floppy_disk:
|
* [vulture](https://github.com/jendrikseipp/vulture) :warning: :floppy_disk:
|
||||||
* [yapf](https://github.com/google/yapf)
|
* [yapf](https://github.com/google/yapf)
|
||||||
@ -504,6 +514,7 @@ formatting.
|
|||||||
* Racket
|
* Racket
|
||||||
* [racket-langserver](https://github.com/jeapostrophe/racket-langserver/tree/master)
|
* [racket-langserver](https://github.com/jeapostrophe/racket-langserver/tree/master)
|
||||||
* [raco](https://docs.racket-lang.org/raco/)
|
* [raco](https://docs.racket-lang.org/raco/)
|
||||||
|
* [raco_fmt](https://docs.racket-lang.org/fmt/)
|
||||||
* Re:VIEW
|
* Re:VIEW
|
||||||
* [redpen](http://redpen.cc/)
|
* [redpen](http://redpen.cc/)
|
||||||
* ReasonML
|
* ReasonML
|
||||||
@ -579,6 +590,7 @@ formatting.
|
|||||||
* [dprint](https://dprint.dev)
|
* [dprint](https://dprint.dev)
|
||||||
* [pgformatter](https://github.com/darold/pgFormatter)
|
* [pgformatter](https://github.com/darold/pgFormatter)
|
||||||
* [sql-lint](https://github.com/joereynolds/sql-lint)
|
* [sql-lint](https://github.com/joereynolds/sql-lint)
|
||||||
|
* [sqlfluff](https://github.com/sqlfluff/sqlfluff)
|
||||||
* [sqlfmt](https://github.com/jackc/sqlfmt)
|
* [sqlfmt](https://github.com/jackc/sqlfmt)
|
||||||
* [sqlformat](https://github.com/andialbrecht/sqlparse)
|
* [sqlformat](https://github.com/andialbrecht/sqlparse)
|
||||||
* [sqlint](https://github.com/purcell/sqlint)
|
* [sqlint](https://github.com/purcell/sqlint)
|
||||||
|
@ -68,6 +68,8 @@ endif
|
|||||||
" specification.
|
" specification.
|
||||||
" https://github.com/nvim-treesitter/nvim-treesitter/blob/master/plugin/nvim-treesitter.vim
|
" https://github.com/nvim-treesitter/nvim-treesitter/blob/master/plugin/nvim-treesitter.vim
|
||||||
if exists('g:loaded_nvim_treesitter')
|
if exists('g:loaded_nvim_treesitter')
|
||||||
|
" deprecated TS* highlight groups
|
||||||
|
" see https://github.com/nvim-treesitter/nvim-treesitter/pull/3656
|
||||||
" # Misc
|
" # Misc
|
||||||
hi! link TSPunctSpecial Special
|
hi! link TSPunctSpecial Special
|
||||||
" # Constants
|
" # Constants
|
||||||
@ -97,6 +99,55 @@ if exists('g:loaded_nvim_treesitter')
|
|||||||
" HTML and JSX tag attributes. By default, this group is linked to TSProperty,
|
" HTML and JSX tag attributes. By default, this group is linked to TSProperty,
|
||||||
" which in turn links to Identifer (white).
|
" which in turn links to Identifer (white).
|
||||||
hi! link TSTagAttribute DraculaGreenItalic
|
hi! link TSTagAttribute DraculaGreenItalic
|
||||||
|
|
||||||
|
if has('nvim-0.8.1')
|
||||||
|
" # Misc
|
||||||
|
hi! link @punctuation.delimiter Delimiter
|
||||||
|
hi! link @punctuation.bracket Normal
|
||||||
|
hi! link @punctuation.special Special
|
||||||
|
" # Constants
|
||||||
|
hi! link @constant Constant
|
||||||
|
hi! link @constant.builtin Constant
|
||||||
|
hi! link @constant.macro Macro
|
||||||
|
hi! link @string.regex String
|
||||||
|
hi! link @string.escape Character
|
||||||
|
hi! link @symbol DraculaPurple
|
||||||
|
hi! link @annotation DraculaYellow
|
||||||
|
hi! link @attribute DraculaGreenItalic
|
||||||
|
hi! link @namespace Structure
|
||||||
|
" # Functions
|
||||||
|
hi! link @function.builtin DraculaCyan
|
||||||
|
hi! link @funcion.macro Function
|
||||||
|
hi! link @parameter DraculaOrangeItalic
|
||||||
|
hi! link @parameter.reference DraculaOrange
|
||||||
|
hi! link @field DraculaOrange
|
||||||
|
hi! link @property Normal
|
||||||
|
hi! link @constructor DraculaCyan
|
||||||
|
" # Keywords
|
||||||
|
hi! link @label DraculaPurpleItalic
|
||||||
|
hi! link @keyword.function DraculaPink
|
||||||
|
hi! link @keyword.operator Operator
|
||||||
|
hi! link @exception DraculaPurple
|
||||||
|
" # Variable
|
||||||
|
hi! link @variable Normal
|
||||||
|
hi! link @variable.builtin DraculaPurpleItalic
|
||||||
|
" # Text
|
||||||
|
hi! link @text Normal
|
||||||
|
hi! link @text.strong DraculaFgBold
|
||||||
|
hi! link @text.emphasis DraculaFg
|
||||||
|
hi! link @text.underline Underlined
|
||||||
|
hi! link @text.title DraculaYellow
|
||||||
|
hi! link @text.literal DraculaYellow
|
||||||
|
hi! link @text.uri DraculaYellow
|
||||||
|
hi! link @text.diff.add DiffAdd
|
||||||
|
hi! link @text.diff.delete DiffDelete
|
||||||
|
" # Tags
|
||||||
|
hi! link @tag DraculaCyan
|
||||||
|
hi! link @tag.delimiter Normal
|
||||||
|
" HTML and JSX tag attributes. By default, this group is linked to TSProperty,
|
||||||
|
" which in turn links to Identifer (white).
|
||||||
|
hi! link @tag.attribute DraculaGreenItalic
|
||||||
|
endif
|
||||||
endif
|
endif
|
||||||
" }}}
|
" }}}
|
||||||
" nvim-cmp: {{{
|
" nvim-cmp: {{{
|
||||||
|
@ -97,6 +97,10 @@ if !exists('g:dracula_colorterm')
|
|||||||
let g:dracula_colorterm = 1
|
let g:dracula_colorterm = 1
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
if !exists('g:dracula_high_contrast_diff')
|
||||||
|
let g:dracula_high_contrast_diff = 0
|
||||||
|
endif
|
||||||
|
|
||||||
"}}}2
|
"}}}2
|
||||||
" Script Helpers: {{{2
|
" Script Helpers: {{{2
|
||||||
|
|
||||||
@ -197,7 +201,12 @@ call s:h('DraculaBoundary', s:comment, s:bgdark)
|
|||||||
call s:h('DraculaWinSeparator', s:comment, s:bgdark)
|
call s:h('DraculaWinSeparator', s:comment, s:bgdark)
|
||||||
call s:h('DraculaLink', s:cyan, s:none, [s:attrs.underline])
|
call s:h('DraculaLink', s:cyan, s:none, [s:attrs.underline])
|
||||||
|
|
||||||
call s:h('DraculaDiffChange', s:orange, s:none)
|
if g:dracula_high_contrast_diff
|
||||||
|
call s:h('DraculaDiffChange', s:yellow, s:purple)
|
||||||
|
else
|
||||||
|
call s:h('DraculaDiffChange', s:orange, s:none)
|
||||||
|
endif
|
||||||
|
|
||||||
call s:h('DraculaDiffText', s:bg, s:orange)
|
call s:h('DraculaDiffText', s:bg, s:orange)
|
||||||
call s:h('DraculaDiffDelete', s:red, s:bgdark)
|
call s:h('DraculaDiffDelete', s:red, s:bgdark)
|
||||||
|
|
||||||
|
@ -93,6 +93,11 @@ terminal emulators, set to 1 to allow underline/undercurl highlights without
|
|||||||
changing the foreground color. >
|
changing the foreground color. >
|
||||||
let g:dracula_full_special_attrs_support = 1
|
let g:dracula_full_special_attrs_support = 1
|
||||||
|
|
||||||
|
* *g:dracula_high_contrast_diff*
|
||||||
|
Use high-contrast color when in diff mode. By default it is disabled, set to
|
||||||
|
1 to enable it.
|
||||||
|
let g:dracula_high_contrast_diff = 1
|
||||||
|
|
||||||
* *g:dracula_inverse*
|
* *g:dracula_inverse*
|
||||||
Include inverse attributes in highlighting >
|
Include inverse attributes in highlighting >
|
||||||
let g:dracula_inverse = 1
|
let g:dracula_inverse = 1
|
||||||
|
@ -60,23 +60,26 @@ lockvar s:SECTCRE s:OPTCRE s:MAX_SECTION_NAME s:MAX_PROPERTY_NAME s:MAX_PROPERTY
|
|||||||
" Read \p config_filename and return the options applicable to
|
" Read \p config_filename and return the options applicable to
|
||||||
" \p target_filename. This is the main entry point in this file.
|
" \p target_filename. This is the main entry point in this file.
|
||||||
function! editorconfig_core#ini#read_ini_file(config_filename, target_filename)
|
function! editorconfig_core#ini#read_ini_file(config_filename, target_filename)
|
||||||
let l:oldenc = &encoding
|
|
||||||
|
|
||||||
if !filereadable(a:config_filename)
|
if !filereadable(a:config_filename)
|
||||||
return {}
|
return {}
|
||||||
endif
|
endif
|
||||||
|
|
||||||
try " so &encoding will always be reset
|
try
|
||||||
let &encoding = 'utf-8' " so readfile() will strip BOM
|
|
||||||
let l:lines = readfile(a:config_filename)
|
let l:lines = readfile(a:config_filename)
|
||||||
|
if &encoding !=? 'utf-8'
|
||||||
|
" strip BOM
|
||||||
|
if len(l:lines) > 0 && l:lines[0][:2] ==# "\xEF\xBB\xBF"
|
||||||
|
let l:lines[0] = l:lines[0][3:]
|
||||||
|
endif
|
||||||
|
" convert from UTF-8 to 'encoding'
|
||||||
|
call map(l:lines, 'iconv(v:val, "utf-8", &encoding)')
|
||||||
|
endif
|
||||||
let result = s:parse(a:config_filename, a:target_filename, l:lines)
|
let result = s:parse(a:config_filename, a:target_filename, l:lines)
|
||||||
catch
|
catch
|
||||||
let &encoding = l:oldenc
|
|
||||||
" rethrow, but with a prefix since throw 'Vim...' fails.
|
" rethrow, but with a prefix since throw 'Vim...' fails.
|
||||||
throw 'Could not read editorconfig file at ' . v:throwpoint . ': ' . string(v:exception)
|
throw 'Could not read editorconfig file at ' . v:throwpoint . ': ' . string(v:exception)
|
||||||
endtry
|
endtry
|
||||||
|
|
||||||
let &encoding = l:oldenc
|
|
||||||
return result
|
return result
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
@ -124,11 +124,11 @@ is restarted.
|
|||||||
|
|
||||||
*g:EditorConfig_max_line_indicator*
|
*g:EditorConfig_max_line_indicator*
|
||||||
The way to show the line where the maximal length is reached. Accepted values
|
The way to show the line where the maximal length is reached. Accepted values
|
||||||
are "line", "fill", otherwise there will be no max line indicator.
|
are "line", "fill" and "exceeding", otherwise there will be no max line
|
||||||
|
indicator.
|
||||||
|
|
||||||
"line": the right column of the max line length column will be
|
"line": the right column of the max line length column will be
|
||||||
highlighted, made possible by setting 'colorcolumn' to
|
highlighted, made possible by adding "+1" to 'colorcolumn'.
|
||||||
"max_line_length + 1".
|
|
||||||
|
|
||||||
"fill": all the columns to the right of the max line length column
|
"fill": all the columns to the right of the max line length column
|
||||||
will be highlighted, made possible by setting 'colorcolumn'
|
will be highlighted, made possible by setting 'colorcolumn'
|
||||||
@ -161,6 +161,23 @@ max_line_length is set:
|
|||||||
<
|
<
|
||||||
This option defaults to 0.
|
This option defaults to 0.
|
||||||
|
|
||||||
|
*g:EditorConfig_softtabstop_space*
|
||||||
|
When spaces are used for indent, Vim's 'softtabstop' feature will make the
|
||||||
|
backspace key delete one indent level. If you turn off that feature (by
|
||||||
|
setting the option to 0), only a single space will be deleted.
|
||||||
|
This option defaults to 1, which enables 'softtabstop' and uses the
|
||||||
|
'shiftwidth' value for it. You can also set this to -1 to automatically follow
|
||||||
|
the current 'shiftwidth' value (since Vim 7.3.693). Or set this to [] if
|
||||||
|
EditorConfig should not touch 'softtabstop' at all.
|
||||||
|
|
||||||
|
*g:EditorConfig_softtabstop_tab*
|
||||||
|
When tabs are used for indent, Vim's 'softtabstop' feature only applies to
|
||||||
|
backspacing over existing runs of spaces.
|
||||||
|
This option defaults to 1, so backspace will delete one indent level worth of
|
||||||
|
spaces; -1 does the same but automatically follows the current 'shiftwidth'
|
||||||
|
value. Set this to 0 to have backspace delete just a single space character.
|
||||||
|
Or set this to [] if EditorConfig should not touch 'softtabstop' at all.
|
||||||
|
|
||||||
*g:EditorConfig_verbose*
|
*g:EditorConfig_verbose*
|
||||||
Set this to 1 if you want debug info printed:
|
Set this to 1 if you want debug info printed:
|
||||||
>
|
>
|
||||||
|
@ -60,6 +60,14 @@ if !exists('g:EditorConfig_disable_rules')
|
|||||||
let g:EditorConfig_disable_rules = []
|
let g:EditorConfig_disable_rules = []
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
if !exists('g:EditorConfig_softtabstop_space')
|
||||||
|
let g:EditorConfig_softtabstop_space = 1
|
||||||
|
endif
|
||||||
|
|
||||||
|
if !exists('g:EditorConfig_softtabstop_tab')
|
||||||
|
let g:EditorConfig_softtabstop_tab = 1
|
||||||
|
endif
|
||||||
|
|
||||||
" Copy some of the globals into script variables --- changes to these
|
" Copy some of the globals into script variables --- changes to these
|
||||||
" globals won't affect the plugin until the plugin is reloaded.
|
" globals won't affect the plugin until the plugin is reloaded.
|
||||||
if exists('g:EditorConfig_core_mode') && !empty(g:EditorConfig_core_mode)
|
if exists('g:EditorConfig_core_mode') && !empty(g:EditorConfig_core_mode)
|
||||||
@ -394,12 +402,18 @@ function! s:ApplyConfig(config) abort " Set the buffer options {{{1
|
|||||||
" value
|
" value
|
||||||
if a:config["indent_size"] == "tab"
|
if a:config["indent_size"] == "tab"
|
||||||
let &l:shiftwidth = &l:tabstop
|
let &l:shiftwidth = &l:tabstop
|
||||||
let &l:softtabstop = &l:shiftwidth
|
if type(g:EditorConfig_softtabstop_tab) != type([])
|
||||||
|
let &l:softtabstop = g:EditorConfig_softtabstop_tab > 0 ?
|
||||||
|
\ &l:shiftwidth : g:EditorConfig_softtabstop_tab
|
||||||
|
endif
|
||||||
else
|
else
|
||||||
let l:indent_size = str2nr(a:config["indent_size"])
|
let l:indent_size = str2nr(a:config["indent_size"])
|
||||||
if l:indent_size > 0
|
if l:indent_size > 0
|
||||||
let &l:shiftwidth = l:indent_size
|
let &l:shiftwidth = l:indent_size
|
||||||
let &l:softtabstop = &l:shiftwidth
|
if type(g:EditorConfig_softtabstop_space) != type([])
|
||||||
|
let &l:softtabstop = g:EditorConfig_softtabstop_space > 0 ?
|
||||||
|
\ &l:shiftwidth : g:EditorConfig_softtabstop_space
|
||||||
|
endif
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
@ -473,7 +487,7 @@ function! s:ApplyConfig(config) abort " Set the buffer options {{{1
|
|||||||
if exists('+colorcolumn')
|
if exists('+colorcolumn')
|
||||||
if l:max_line_length > 0
|
if l:max_line_length > 0
|
||||||
if g:EditorConfig_max_line_indicator == 'line'
|
if g:EditorConfig_max_line_indicator == 'line'
|
||||||
let &l:colorcolumn = l:max_line_length + 1
|
setlocal colorcolumn+=+1
|
||||||
elseif g:EditorConfig_max_line_indicator == 'fill' &&
|
elseif g:EditorConfig_max_line_indicator == 'fill' &&
|
||||||
\ l:max_line_length < &l:columns
|
\ l:max_line_length < &l:columns
|
||||||
" Fill only if the columns of screen is large enough
|
" Fill only if the columns of screen is large enough
|
||||||
|
@ -160,3 +160,10 @@ if extcore
|
|||||||
)
|
)
|
||||||
test_instance vim
|
test_instance vim
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# Test the vim core with latin1 encoding
|
||||||
|
(lambda do
|
||||||
|
puts 'Testing with express vim_core mode'
|
||||||
|
vim = create_vim("set encoding=latin1")
|
||||||
|
test_instance vim
|
||||||
|
end).call
|
||||||
|
@ -1,13 +1,73 @@
|
|||||||
if exists("b:did_indent")
|
" Only load this indent file when no other was loaded.
|
||||||
finish
|
if exists('b:did_indent')
|
||||||
|
finish
|
||||||
endif
|
endif
|
||||||
let b:did_indent = 1
|
let b:did_indent = 1
|
||||||
|
|
||||||
setlocal indentexpr=
|
setlocal indentexpr=GetNginxIndent()
|
||||||
|
|
||||||
" cindent actually works for nginx' simple file structure
|
setlocal indentkeys=0{,0},0#,!^F,o,O
|
||||||
setlocal cindent
|
|
||||||
" Just make sure that the comments are not reset as defs would be.
|
|
||||||
setlocal cinkeys-=0#
|
|
||||||
|
|
||||||
let b:undo_indent = "setl cin< cink< inde<"
|
let b:undo_indent = 'setl inde< indk<'
|
||||||
|
|
||||||
|
" Only define the function once.
|
||||||
|
if exists('*GetNginxIndent')
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
function! GetNginxIndent() abort
|
||||||
|
let plnum = s:PrevNotAsBlank(v:lnum - 1)
|
||||||
|
|
||||||
|
" Hit the start of the file, use zero indent.
|
||||||
|
if plnum == 0
|
||||||
|
return 0
|
||||||
|
endif
|
||||||
|
|
||||||
|
let ind = indent(plnum)
|
||||||
|
|
||||||
|
" Add a 'shiftwidth' after '{'
|
||||||
|
if s:AsEndWith(getline(plnum), '{')
|
||||||
|
let ind = ind + shiftwidth()
|
||||||
|
end
|
||||||
|
|
||||||
|
" Subtract a 'shiftwidth' on '}'
|
||||||
|
" This is the part that requires 'indentkeys'.
|
||||||
|
if getline(v:lnum) =~ '^\s*}'
|
||||||
|
let ind = ind - shiftwidth()
|
||||||
|
endif
|
||||||
|
|
||||||
|
let pplnum = s:PrevNotAsBlank(plnum - 1)
|
||||||
|
|
||||||
|
if s:IsLineContinuation(plnum)
|
||||||
|
if !s:IsLineContinuation(pplnum)
|
||||||
|
let ind = ind + shiftwidth()
|
||||||
|
end
|
||||||
|
else
|
||||||
|
if s:IsLineContinuation(pplnum)
|
||||||
|
let ind = ind - shiftwidth()
|
||||||
|
end
|
||||||
|
endif
|
||||||
|
|
||||||
|
return ind
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
" Find the first line at or above {lnum} that is non-blank and not a comment.
|
||||||
|
function! s:PrevNotAsBlank(lnum) abort
|
||||||
|
let lnum = prevnonblank(a:lnum)
|
||||||
|
while lnum > 0
|
||||||
|
if getline(lnum) !~ '^\s*#'
|
||||||
|
break
|
||||||
|
endif
|
||||||
|
let lnum = prevnonblank(lnum - 1)
|
||||||
|
endwhile
|
||||||
|
return lnum
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
" Check whether {line} ends with {pat}, ignoring trailing comments.
|
||||||
|
function! s:AsEndWith(line, pat) abort
|
||||||
|
return a:line =~ a:pat . '\m\s*\%(#.*\)\?$'
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! s:IsLineContinuation(lnum) abort
|
||||||
|
return a:lnum > 0 && !s:AsEndWith(getline(a:lnum), '[;{}]')
|
||||||
|
endfunction
|
||||||
|
@ -1940,7 +1940,7 @@ syn keyword ngxDirectiveThirdParty srcache_default_expire
|
|||||||
syn keyword ngxDirectiveThirdParty srcache_max_expire
|
syn keyword ngxDirectiveThirdParty srcache_max_expire
|
||||||
|
|
||||||
" SSSD Info Module <https://github.com/veruu/ngx_sssd_info>
|
" SSSD Info Module <https://github.com/veruu/ngx_sssd_info>
|
||||||
" Retrieves additional attributes from SSSD for current authentizated user
|
" Retrives additional attributes from SSSD for current authentizated user
|
||||||
syn keyword ngxDirectiveThirdParty sssd_info
|
syn keyword ngxDirectiveThirdParty sssd_info
|
||||||
syn keyword ngxDirectiveThirdParty sssd_info_output_to
|
syn keyword ngxDirectiveThirdParty sssd_info_output_to
|
||||||
syn keyword ngxDirectiveThirdParty sssd_info_groups
|
syn keyword ngxDirectiveThirdParty sssd_info_groups
|
||||||
|
@ -18,7 +18,7 @@ function! s:strip_white_space(l,r,line) abort
|
|||||||
if l[-1:] ==# ' ' && stridx(a:line,l) == -1 && stridx(a:line,l[0:-2]) == 0
|
if l[-1:] ==# ' ' && stridx(a:line,l) == -1 && stridx(a:line,l[0:-2]) == 0
|
||||||
let l = l[:-2]
|
let l = l[:-2]
|
||||||
endif
|
endif
|
||||||
if r[0] ==# ' ' && a:line[-strlen(r):] != r && a:line[1-strlen(r):] == r[1:]
|
if r[0] ==# ' ' && (' ' . a:line)[-strlen(r)-1:] != r && a:line[-strlen(r):] == r[1:]
|
||||||
let r = r[1:]
|
let r = r[1:]
|
||||||
endif
|
endif
|
||||||
return [l, r]
|
return [l, r]
|
||||||
|
@ -470,7 +470,7 @@ function! s:GitCmd() abort
|
|||||||
let string = strpart(string, len(arg))
|
let string = strpart(string, len(arg))
|
||||||
let arg = substitute(arg, '^\s\+', '', '')
|
let arg = substitute(arg, '^\s\+', '', '')
|
||||||
let arg = substitute(arg,
|
let arg = substitute(arg,
|
||||||
\ '\(' . dquote . '''\%(''''\|[^'']\)*''\|\\[' . s:fnameescape . ']\|^\\[>+-]\|!\d*\)\|' . s:expand,
|
\ '\(' . dquote . '''\%(''''\|[^'']\)*''\|\\[' . s:fnameescape . ']\|^\\[>+-]\|' . s:commit_expand . '\)\|' . s:expand,
|
||||||
\ '\=submatch(0)[0] ==# "\\" ? submatch(0)[1] : submatch(0)[1:-2]', 'g')
|
\ '\=submatch(0)[0] ==# "\\" ? submatch(0)[1] : submatch(0)[1:-2]', 'g')
|
||||||
call add(list, arg)
|
call add(list, arg)
|
||||||
endwhile
|
endwhile
|
||||||
@ -1958,6 +1958,7 @@ endfunction
|
|||||||
let s:var = '\%(<\%(cword\|cWORD\|cexpr\|cfile\|sfile\|slnum\|afile\|abuf\|amatch' . (has('clientserver') ? '\|client' : '') . '\)>\|%\|#<\=\d\+\|##\=\)'
|
let s:var = '\%(<\%(cword\|cWORD\|cexpr\|cfile\|sfile\|slnum\|afile\|abuf\|amatch' . (has('clientserver') ? '\|client' : '') . '\)>\|%\|#<\=\d\+\|##\=\)'
|
||||||
let s:flag = '\%(:[p8~.htre]\|:g\=s\(.\).\{-\}\1.\{-\}\1\)'
|
let s:flag = '\%(:[p8~.htre]\|:g\=s\(.\).\{-\}\1.\{-\}\1\)'
|
||||||
let s:expand = '\%(\(' . s:var . '\)\(' . s:flag . '*\)\(:S\)\=\)'
|
let s:expand = '\%(\(' . s:var . '\)\(' . s:flag . '*\)\(:S\)\=\)'
|
||||||
|
let s:commit_expand = '!\\\@!#\=\d*\|!%'
|
||||||
|
|
||||||
function! s:BufName(var) abort
|
function! s:BufName(var) abort
|
||||||
if a:var ==# '%'
|
if a:var ==# '%'
|
||||||
@ -1978,8 +1979,8 @@ function! s:ExpandVar(other, var, flags, esc, ...) abort
|
|||||||
return substitute(a:other[1:-2], "''", "'", "g")
|
return substitute(a:other[1:-2], "''", "'", "g")
|
||||||
elseif a:other =~# '^"'
|
elseif a:other =~# '^"'
|
||||||
return substitute(a:other[1:-2], '""', '"', "g")
|
return substitute(a:other[1:-2], '""', '"', "g")
|
||||||
elseif a:other =~# '^!'
|
elseif a:other =~# '^[!`]'
|
||||||
let buffer = s:BufName(len(a:other) > 1 ? '#'. a:other[1:-1] : '%')
|
let buffer = s:BufName(a:other =~# '[0-9#]' ? '#' . matchstr(a:other, '\d\+') : '%')
|
||||||
let owner = s:Owner(buffer)
|
let owner = s:Owner(buffer)
|
||||||
return len(owner) ? owner : '@'
|
return len(owner) ? owner : '@'
|
||||||
elseif a:other =~# '^\~[~.]$'
|
elseif a:other =~# '^\~[~.]$'
|
||||||
@ -2033,7 +2034,11 @@ function! s:ExpandVar(other, var, flags, esc, ...) abort
|
|||||||
return join(files, "\1")
|
return join(files, "\1")
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
let s:fnameescape = " \t\n*?[{`$\\%#'\"|!<"
|
if has('win32')
|
||||||
|
let s:fnameescape = " \t\n*?`%#'\"|!<"
|
||||||
|
else
|
||||||
|
let s:fnameescape = " \t\n*?[{`$\\%#'\"|!<"
|
||||||
|
endif
|
||||||
|
|
||||||
function! s:Expand(rev, ...) abort
|
function! s:Expand(rev, ...) abort
|
||||||
if a:rev =~# '^>' && s:Slash(@%) =~# '^fugitive://' && empty(s:DirCommitFile(@%)[1])
|
if a:rev =~# '^>' && s:Slash(@%) =~# '^fugitive://' && empty(s:DirCommitFile(@%)[1])
|
||||||
@ -2060,13 +2065,13 @@ function! s:Expand(rev, ...) abort
|
|||||||
let file = a:rev
|
let file = a:rev
|
||||||
endif
|
endif
|
||||||
return substitute(file,
|
return substitute(file,
|
||||||
\ '\(\\[' . s:fnameescape . ']\|^\\[>+-]\|!\d*\|^\~[~.]\)\|' . s:expand,
|
\ '\(\\[' . s:fnameescape . ']\|^\\[>+-]\|' . s:commit_expand . '\|^\~[~.]\)\|' . s:expand,
|
||||||
\ '\=tr(s:ExpandVar(submatch(1),submatch(2),submatch(3),"", a:0 ? a:1 : getcwd()), "\1", " ")', 'g')
|
\ '\=tr(s:ExpandVar(submatch(1),submatch(2),submatch(3),"", a:0 ? a:1 : getcwd()), "\1", " ")', 'g')
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! fugitive#Expand(object) abort
|
function! fugitive#Expand(object) abort
|
||||||
return substitute(a:object,
|
return substitute(a:object,
|
||||||
\ '\(\\[' . s:fnameescape . ']\|^\\[>+-]\|!\d*\|^\~[~.]\)\|' . s:expand,
|
\ '\(\\[' . s:fnameescape . ']\|^\\[>+-]\|' . s:commit_expand . '\|^\~[~.]\)\|' . s:expand,
|
||||||
\ '\=tr(s:ExpandVar(submatch(1),submatch(2),submatch(3),submatch(5)), "\1", " ")', 'g')
|
\ '\=tr(s:ExpandVar(submatch(1),submatch(2),submatch(3),submatch(5)), "\1", " ")', 'g')
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
@ -2087,7 +2092,7 @@ function! s:SplitExpandChain(string, ...) abort
|
|||||||
\ '\=s:DotRelative(s:Slash(simplify(getcwd() . "/" . submatch(0))), cwd)', '')
|
\ '\=s:DotRelative(s:Slash(simplify(getcwd() . "/" . submatch(0))), cwd)', '')
|
||||||
endif
|
endif
|
||||||
let arg = substitute(arg,
|
let arg = substitute(arg,
|
||||||
\ '\(' . dquote . '''\%(''''\|[^'']\)*''\|\\[' . s:fnameescape . ']\|^\\[>+-]\|!\d*\|^\~[~]\|^\~\w*\|\$\w\+\)\|' . s:expand,
|
\ '\(' . dquote . '''\%(''''\|[^'']\)*''\|\\[' . s:fnameescape . ']\|^\\[>+-]\|' . s:commit_expand . '\|^\~[~]\|^\~\w*\|\$\w\+\)\|' . s:expand,
|
||||||
\ '\=s:ExpandVar(submatch(1),submatch(2),submatch(3),submatch(5), cwd)', 'g')
|
\ '\=s:ExpandVar(submatch(1),submatch(2),submatch(3),submatch(5), cwd)', 'g')
|
||||||
call extend(list, split(arg, "\1", 1))
|
call extend(list, split(arg, "\1", 1))
|
||||||
if arg ==# '--'
|
if arg ==# '--'
|
||||||
@ -7548,7 +7553,7 @@ function! s:SquashArgument(...) abort
|
|||||||
if &filetype == 'fugitive'
|
if &filetype == 'fugitive'
|
||||||
let commit = matchstr(getline('.'), '^\%(\%(\x\x\x\)\@!\l\+\s\+\)\=\zs[0-9a-f]\{4,\}\ze \|^' . s:ref_header . ': \zs\S\+')
|
let commit = matchstr(getline('.'), '^\%(\%(\x\x\x\)\@!\l\+\s\+\)\=\zs[0-9a-f]\{4,\}\ze \|^' . s:ref_header . ': \zs\S\+')
|
||||||
elseif has_key(s:temp_files, s:cpath(expand('%:p')))
|
elseif has_key(s:temp_files, s:cpath(expand('%:p')))
|
||||||
let commit = matchstr(getline('.'), '\S\@<!\x\{4,\}\>')
|
let commit = matchstr(getline('.'), '\S\@<!\x\{4,\}\S\@!')
|
||||||
else
|
else
|
||||||
let commit = s:Owner(@%)
|
let commit = s:Owner(@%)
|
||||||
endif
|
endif
|
||||||
@ -7594,7 +7599,7 @@ function! s:HunkPosition(lnum) abort
|
|||||||
let lnum -= 1
|
let lnum -= 1
|
||||||
let line_char = getline(lnum)[0]
|
let line_char = getline(lnum)[0]
|
||||||
endwhile
|
endwhile
|
||||||
let starts = matchlist(getline(lnum), '^@@\+[ 0-9,-]* -\(\d\+\),\d\+ +\(\d\+\),')
|
let starts = matchlist(getline(lnum), '^@@\+[ 0-9,-]* -\(\d\+\)\%(,\d\+\)\= +\(\d\+\)[ ,]')
|
||||||
if empty(starts)
|
if empty(starts)
|
||||||
return [0, 0, 0]
|
return [0, 0, 0]
|
||||||
endif
|
endif
|
||||||
|
@ -70,12 +70,10 @@ that are part of Git repositories).
|
|||||||
O jump to patch or blob in new tab
|
O jump to patch or blob in new tab
|
||||||
p jump to patch or blob in preview window
|
p jump to patch or blob in preview window
|
||||||
- reblame at commit
|
- reblame at commit
|
||||||
~ reblame at commit~[count]
|
|
||||||
P reblame at commit^[count]
|
|
||||||
|
|
||||||
*g:fugitive_dynamic_colors*
|
*g:fugitive_dynamic_colors*
|
||||||
In the GUI or a 256 color terminal, commit hashes will
|
In the GUI or a 256 color terminal, commit hashes will
|
||||||
highlighted in different colors. To disable this:
|
be highlighted in different colors. To disable this:
|
||||||
>
|
>
|
||||||
let g:fugitive_dynamic_colors = 0
|
let g:fugitive_dynamic_colors = 0
|
||||||
<
|
<
|
||||||
|
@ -140,7 +140,7 @@ function! FugitiveExecute(args, ...) abort
|
|||||||
return call('fugitive#Execute', [a:args] + a:000)
|
return call('fugitive#Execute', [a:args] + a:000)
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
" FugitiveShellCommand() turns an array of arugments into a Git command string
|
" FugitiveShellCommand() turns an array of arguments into a Git command string
|
||||||
" which can be executed with functions like system() and commands like :!.
|
" which can be executed with functions like system() and commands like :!.
|
||||||
" Integer arguments will be treated as buffer numbers, and the appropriate
|
" Integer arguments will be treated as buffer numbers, and the appropriate
|
||||||
" relative path inserted in their place.
|
" relative path inserted in their place.
|
||||||
|
@ -501,18 +501,15 @@ endfunction
|
|||||||
" Floating window: does not care where cursor is.
|
" Floating window: does not care where cursor is.
|
||||||
" Preview window: assumes cursor is in preview window.
|
" Preview window: assumes cursor is in preview window.
|
||||||
function! s:populate_hunk_preview_window(header, body)
|
function! s:populate_hunk_preview_window(header, body)
|
||||||
let body_length = len(a:body)
|
|
||||||
|
|
||||||
if g:gitgutter_preview_win_floating
|
if g:gitgutter_preview_win_floating
|
||||||
if exists('*nvim_open_win')
|
if exists('*nvim_open_win')
|
||||||
let height = min([body_length, g:gitgutter_floating_window_options.height])
|
|
||||||
|
|
||||||
" Assumes cursor is not in previewing window.
|
" Assumes cursor is not in previewing window.
|
||||||
call nvim_buf_set_var(winbufnr(s:winid), 'hunk_header', a:header)
|
call nvim_buf_set_var(winbufnr(s:winid), 'hunk_header', a:header)
|
||||||
|
|
||||||
let [_scrolloff, &scrolloff] = [&scrolloff, 0]
|
let [_scrolloff, &scrolloff] = [&scrolloff, 0]
|
||||||
|
|
||||||
let width = max(map(copy(a:body), 'strdisplaywidth(v:val)'))
|
let [width, height] = s:screen_lines(a:body)
|
||||||
|
let height = min([height, g:gitgutter_floating_window_options.height])
|
||||||
call nvim_win_set_width(s:winid, width)
|
call nvim_win_set_width(s:winid, width)
|
||||||
call nvim_win_set_height(s:winid, height)
|
call nvim_win_set_height(s:winid, height)
|
||||||
|
|
||||||
@ -548,9 +545,7 @@ function! s:populate_hunk_preview_window(header, body)
|
|||||||
call setline(1, a:body)
|
call setline(1, a:body)
|
||||||
setlocal nomodified
|
setlocal nomodified
|
||||||
|
|
||||||
normal! G$
|
let [_, height] = s:screen_lines(a:body)
|
||||||
let hunk_height = max([body_length, winline()])
|
|
||||||
let height = min([hunk_height, &previewheight])
|
|
||||||
execute 'resize' height
|
execute 'resize' height
|
||||||
1
|
1
|
||||||
|
|
||||||
@ -565,6 +560,27 @@ function! s:populate_hunk_preview_window(header, body)
|
|||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
|
||||||
|
" Calculates the number of columns and the number of screen lines the given
|
||||||
|
" array of lines will take up, taking account of wrapping.
|
||||||
|
function! s:screen_lines(lines)
|
||||||
|
let [_virtualedit, &virtualedit]=[&virtualedit, 'all']
|
||||||
|
let cursor = getcurpos()
|
||||||
|
normal! g$
|
||||||
|
let available_width = virtcol('.')
|
||||||
|
call setpos('.', cursor)
|
||||||
|
let &virtualedit=_virtualedit
|
||||||
|
let width = min([max(map(copy(a:lines), 'strdisplaywidth(v:val)')), available_width])
|
||||||
|
|
||||||
|
if exists('*reduce')
|
||||||
|
let height = reduce(a:lines, { acc, val -> acc + strdisplaywidth(val) / width + (strdisplaywidth(val) % width == 0 ? 0 : 1) }, 0)
|
||||||
|
else
|
||||||
|
let height = eval(join(map(copy(a:lines), 'strdisplaywidth(v:val) / width + (strdisplaywidth(v:val) % width == 0 ? 0 : 1)'), '+'))
|
||||||
|
endif
|
||||||
|
|
||||||
|
return [width, height]
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
|
||||||
function! s:enable_staging_from_hunk_preview_window()
|
function! s:enable_staging_from_hunk_preview_window()
|
||||||
augroup gitgutter_hunk_preview
|
augroup gitgutter_hunk_preview
|
||||||
autocmd!
|
autocmd!
|
||||||
|
@ -25,7 +25,7 @@ if get(g:, 'vim_markdown_folding_style_pythonic', 0)
|
|||||||
let b:fenced_block = 0
|
let b:fenced_block = 0
|
||||||
endif
|
endif
|
||||||
" else, if we're caring about front matter
|
" else, if we're caring about front matter
|
||||||
elseif g:vim_markdown_frontmatter == 1
|
elseif get(g:, 'vim_markdown_frontmatter', 0) == 1
|
||||||
" if we're in front matter and not on line 1
|
" if we're in front matter and not on line 1
|
||||||
if b:front_matter == 1 && a:lnum > 2
|
if b:front_matter == 1 && a:lnum > 2
|
||||||
let l0 = getline(a:lnum-1)
|
let l0 = getline(a:lnum-1)
|
||||||
@ -111,7 +111,7 @@ else " vim_markdown_folding_style_pythonic == 0
|
|||||||
elseif b:fenced_block == 1
|
elseif b:fenced_block == 1
|
||||||
let b:fenced_block = 0
|
let b:fenced_block = 0
|
||||||
endif
|
endif
|
||||||
elseif g:vim_markdown_frontmatter == 1
|
elseif get(g:, 'vim_markdown_frontmatter', 0) == 1
|
||||||
if b:front_matter == 1
|
if b:front_matter == 1
|
||||||
if l0 ==# '---'
|
if l0 ==# '---'
|
||||||
let b:front_matter = 0
|
let b:front_matter = 0
|
||||||
|
@ -494,7 +494,9 @@ endfunction
|
|||||||
function! s:SetexToAtx(line1, line2)
|
function! s:SetexToAtx(line1, line2)
|
||||||
let l:originalNumLines = line('$')
|
let l:originalNumLines = line('$')
|
||||||
execute 'silent! ' . a:line1 . ',' . a:line2 . 'substitute/\v(.*\S.*)\n\=+$/# \1/'
|
execute 'silent! ' . a:line1 . ',' . a:line2 . 'substitute/\v(.*\S.*)\n\=+$/# \1/'
|
||||||
execute 'silent! ' . a:line1 . ',' . a:line2 . 'substitute/\v(.*\S.*)\n-+$/## \1/'
|
|
||||||
|
let l:changed = l:originalNumLines - line('$')
|
||||||
|
execute 'silent! ' . a:line1 . ',' . (a:line2 - l:changed) . 'substitute/\v(.*\S.*)\n-+$/## \1'
|
||||||
return l:originalNumLines - line('$')
|
return l:originalNumLines - line('$')
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
@ -546,7 +548,7 @@ function! s:TableFormat()
|
|||||||
let l:flags = (&gdefault ? '' : 'g')
|
let l:flags = (&gdefault ? '' : 'g')
|
||||||
execute 's/\(:\@<!-:\@!\|[^|:-]\)//e' . l:flags
|
execute 's/\(:\@<!-:\@!\|[^|:-]\)//e' . l:flags
|
||||||
execute 's/--/-/e' . l:flags
|
execute 's/--/-/e' . l:flags
|
||||||
Tabularize /|
|
Tabularize /\(\\\)\@<!|
|
||||||
" Move colons for alignment to left or right side of the cell.
|
" Move colons for alignment to left or right side of the cell.
|
||||||
execute 's/:\( \+\)|/\1:|/e' . l:flags
|
execute 's/:\( \+\)|/\1:|/e' . l:flags
|
||||||
execute 's/|\( \+\):/|:\1/e' . l:flags
|
execute 's/|\( \+\):/|:\1/e' . l:flags
|
||||||
@ -854,19 +856,23 @@ function! s:SyntaxInclude(filetype)
|
|||||||
return grouplistname
|
return grouplistname
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
function! s:IsHighlightSourcesEnabledForBuffer()
|
||||||
|
" Enable for markdown buffers, and for liquid buffers with markdown format
|
||||||
|
return &filetype =~# 'markdown' || get(b:, 'liquid_subtype', '') =~# 'markdown'
|
||||||
|
endfunction
|
||||||
|
|
||||||
function! s:MarkdownRefreshSyntax(force)
|
function! s:MarkdownRefreshSyntax(force)
|
||||||
" Use != to compare &syntax's value to use the same logic run on
|
" Use != to compare &syntax's value to use the same logic run on
|
||||||
" $VIMRUNTIME/syntax/synload.vim.
|
" $VIMRUNTIME/syntax/synload.vim.
|
||||||
"
|
"
|
||||||
" vint: next-line -ProhibitEqualTildeOperator
|
" vint: next-line -ProhibitEqualTildeOperator
|
||||||
if &filetype =~# 'markdown' && line('$') > 1 && &syntax != 'OFF'
|
if s:IsHighlightSourcesEnabledForBuffer() && line('$') > 1 && &syntax != 'OFF'
|
||||||
call s:MarkdownHighlightSources(a:force)
|
call s:MarkdownHighlightSources(a:force)
|
||||||
endif
|
endif
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! s:MarkdownClearSyntaxVariables()
|
function! s:MarkdownClearSyntaxVariables()
|
||||||
if &filetype =~# 'markdown'
|
if s:IsHighlightSourcesEnabledForBuffer()
|
||||||
unlet! b:mkd_included_filetypes
|
unlet! b:mkd_included_filetypes
|
||||||
endif
|
endif
|
||||||
endfunction
|
endfunction
|
||||||
|
@ -109,8 +109,9 @@ syn region mkdFootnote start="\[^" end="\]"
|
|||||||
syn match mkdCode /^\s*\n\(\(\s\{8,}[^ ]\|\t\t\+[^\t]\).*\n\)\+/
|
syn match mkdCode /^\s*\n\(\(\s\{8,}[^ ]\|\t\t\+[^\t]\).*\n\)\+/
|
||||||
syn match mkdCode /\%^\(\(\s\{4,}[^ ]\|\t\+[^\t]\).*\n\)\+/
|
syn match mkdCode /\%^\(\(\s\{4,}[^ ]\|\t\+[^\t]\).*\n\)\+/
|
||||||
syn match mkdCode /^\s*\n\(\(\s\{4,}[^ ]\|\t\+[^\t]\).*\n\)\+/ contained
|
syn match mkdCode /^\s*\n\(\(\s\{4,}[^ ]\|\t\+[^\t]\).*\n\)\+/ contained
|
||||||
syn match mkdListItem /^\s*\%([-*+]\|\d\+\.\)\ze\s\+/ contained
|
syn match mkdListItem /^\s*\%([-*+]\|\d\+\.\)\ze\s\+/ contained nextgroup=mkdListItemCheckbox
|
||||||
syn region mkdListItemLine start="^\s*\%([-*+]\|\d\+\.\)\s\+" end="$" oneline contains=@mkdNonListItem,mkdListItem,@Spell
|
syn match mkdListItemCheckbox /\[[xXoO ]\]\ze\s\+/ contained contains=mkdListItem
|
||||||
|
syn region mkdListItemLine start="^\s*\%([-*+]\|\d\+\.\)\s\+" end="$" oneline contains=@mkdNonListItem,mkdListItem,mkdListItemCheckbox,@Spell
|
||||||
syn region mkdNonListItemBlock start="\(\%^\(\s*\([-*+]\|\d\+\.\)\s\+\)\@!\|\n\(\_^\_$\|\s\{4,}[^ ]\|\t+[^\t]\)\@!\)" end="^\(\s*\([-*+]\|\d\+\.\)\s\+\)\@=" contains=@mkdNonListItem,@Spell
|
syn region mkdNonListItemBlock start="\(\%^\(\s*\([-*+]\|\d\+\.\)\s\+\)\@!\|\n\(\_^\_$\|\s\{4,}[^ ]\|\t+[^\t]\)\@!\)" end="^\(\s*\([-*+]\|\d\+\.\)\s\+\)\@=" contains=@mkdNonListItem,@Spell
|
||||||
syn match mkdRule /^\s*\*\s\{0,1}\*\s\{0,1}\*\(\*\|\s\)*$/
|
syn match mkdRule /^\s*\*\s\{0,1}\*\s\{0,1}\*\(\*\|\s\)*$/
|
||||||
syn match mkdRule /^\s*-\s\{0,1}-\s\{0,1}-\(-\|\s\)*$/
|
syn match mkdRule /^\s*-\s\{0,1}-\s\{0,1}-\(-\|\s\)*$/
|
||||||
@ -158,25 +159,26 @@ endif
|
|||||||
syn cluster mkdNonListItem contains=@htmlTop,htmlItalic,htmlBold,htmlBoldItalic,mkdFootnotes,mkdInlineURL,mkdLink,mkdLinkDef,mkdLineBreak,mkdBlockquote,mkdCode,mkdRule,htmlH1,htmlH2,htmlH3,htmlH4,htmlH5,htmlH6,mkdMath,mkdStrike
|
syn cluster mkdNonListItem contains=@htmlTop,htmlItalic,htmlBold,htmlBoldItalic,mkdFootnotes,mkdInlineURL,mkdLink,mkdLinkDef,mkdLineBreak,mkdBlockquote,mkdCode,mkdRule,htmlH1,htmlH2,htmlH3,htmlH4,htmlH5,htmlH6,mkdMath,mkdStrike
|
||||||
|
|
||||||
"highlighting for Markdown groups
|
"highlighting for Markdown groups
|
||||||
HtmlHiLink mkdString String
|
HtmlHiLink mkdString String
|
||||||
HtmlHiLink mkdCode String
|
HtmlHiLink mkdCode String
|
||||||
HtmlHiLink mkdCodeDelimiter String
|
HtmlHiLink mkdCodeDelimiter String
|
||||||
HtmlHiLink mkdCodeStart String
|
HtmlHiLink mkdCodeStart String
|
||||||
HtmlHiLink mkdCodeEnd String
|
HtmlHiLink mkdCodeEnd String
|
||||||
HtmlHiLink mkdFootnote Comment
|
HtmlHiLink mkdFootnote Comment
|
||||||
HtmlHiLink mkdBlockquote Comment
|
HtmlHiLink mkdBlockquote Comment
|
||||||
HtmlHiLink mkdListItem Identifier
|
HtmlHiLink mkdListItem Identifier
|
||||||
HtmlHiLink mkdRule Identifier
|
HtmlHiLink mkdListItemCheckbox Identifier
|
||||||
HtmlHiLink mkdLineBreak Visual
|
HtmlHiLink mkdRule Identifier
|
||||||
HtmlHiLink mkdFootnotes htmlLink
|
HtmlHiLink mkdLineBreak Visual
|
||||||
HtmlHiLink mkdLink htmlLink
|
HtmlHiLink mkdFootnotes htmlLink
|
||||||
HtmlHiLink mkdURL htmlString
|
HtmlHiLink mkdLink htmlLink
|
||||||
HtmlHiLink mkdInlineURL htmlLink
|
HtmlHiLink mkdURL htmlString
|
||||||
HtmlHiLink mkdID Identifier
|
HtmlHiLink mkdInlineURL htmlLink
|
||||||
HtmlHiLink mkdLinkDef mkdID
|
HtmlHiLink mkdID Identifier
|
||||||
HtmlHiLink mkdLinkDefTarget mkdURL
|
HtmlHiLink mkdLinkDef mkdID
|
||||||
HtmlHiLink mkdLinkTitle htmlString
|
HtmlHiLink mkdLinkDefTarget mkdURL
|
||||||
HtmlHiLink mkdDelimiter Delimiter
|
HtmlHiLink mkdLinkTitle htmlString
|
||||||
|
HtmlHiLink mkdDelimiter Delimiter
|
||||||
|
|
||||||
let b:current_syntax = 'mkd'
|
let b:current_syntax = 'mkd'
|
||||||
|
|
||||||
|
116
sources_non_forked/vim-markdown/test/header-decrease.vader
Normal file
116
sources_non_forked/vim-markdown/test/header-decrease.vader
Normal file
@ -0,0 +1,116 @@
|
|||||||
|
Given markdown;
|
||||||
|
# a
|
||||||
|
|
||||||
|
## b
|
||||||
|
|
||||||
|
### c
|
||||||
|
|
||||||
|
#### d
|
||||||
|
|
||||||
|
##### e
|
||||||
|
|
||||||
|
Execute (HeaderIncrease without forbidden level):
|
||||||
|
:HeaderIncrease
|
||||||
|
|
||||||
|
Expect (increase level of all headers):
|
||||||
|
## a
|
||||||
|
|
||||||
|
### b
|
||||||
|
|
||||||
|
#### c
|
||||||
|
|
||||||
|
##### d
|
||||||
|
|
||||||
|
###### e
|
||||||
|
|
||||||
|
Given markdown;
|
||||||
|
# a
|
||||||
|
|
||||||
|
###### b
|
||||||
|
|
||||||
|
Execute (HeaderIncrease with forbidden level):
|
||||||
|
:HeaderIncrease
|
||||||
|
|
||||||
|
Expect (no changes):
|
||||||
|
# a
|
||||||
|
|
||||||
|
###### b
|
||||||
|
|
||||||
|
Given markdown;
|
||||||
|
## a
|
||||||
|
|
||||||
|
### b
|
||||||
|
|
||||||
|
#### c
|
||||||
|
|
||||||
|
##### d
|
||||||
|
|
||||||
|
###### e
|
||||||
|
|
||||||
|
Execute (HeaderDecrease without forbidden level):
|
||||||
|
:HeaderDecrease
|
||||||
|
|
||||||
|
Expect (decrease level of all headers):
|
||||||
|
# a
|
||||||
|
|
||||||
|
## b
|
||||||
|
|
||||||
|
### c
|
||||||
|
|
||||||
|
#### d
|
||||||
|
|
||||||
|
##### e
|
||||||
|
|
||||||
|
Given markdown;
|
||||||
|
# a
|
||||||
|
|
||||||
|
## b
|
||||||
|
|
||||||
|
### c
|
||||||
|
|
||||||
|
#### d
|
||||||
|
|
||||||
|
##### e
|
||||||
|
|
||||||
|
###### f
|
||||||
|
|
||||||
|
Execute (HeaderDecrease with forbidden level):
|
||||||
|
:HeaderDecrease
|
||||||
|
|
||||||
|
Expect (no changes):
|
||||||
|
# a
|
||||||
|
|
||||||
|
## b
|
||||||
|
|
||||||
|
### c
|
||||||
|
|
||||||
|
#### d
|
||||||
|
|
||||||
|
##### e
|
||||||
|
|
||||||
|
###### f
|
||||||
|
|
||||||
|
Given markdown;
|
||||||
|
a
|
||||||
|
=
|
||||||
|
|
||||||
|
b
|
||||||
|
-
|
||||||
|
|
||||||
|
Execute (HeaderIncrease with setext headers):
|
||||||
|
:HeaderIncrease
|
||||||
|
|
||||||
|
Expect (convert to atx headers):
|
||||||
|
## a
|
||||||
|
|
||||||
|
### b
|
||||||
|
|
||||||
|
Given markdown;
|
||||||
|
a
|
||||||
|
-
|
||||||
|
|
||||||
|
Execute (HeaderDecrease with setext headers):
|
||||||
|
:HeaderDecrease
|
||||||
|
|
||||||
|
Expect (convert to atx headers):
|
||||||
|
# a
|
48
sources_non_forked/vim-markdown/test/setextoatx.vader
Normal file
48
sources_non_forked/vim-markdown/test/setextoatx.vader
Normal file
@ -0,0 +1,48 @@
|
|||||||
|
Given markdown;
|
||||||
|
# a
|
||||||
|
|
||||||
|
a
|
||||||
|
=
|
||||||
|
|
||||||
|
## b
|
||||||
|
|
||||||
|
b
|
||||||
|
-
|
||||||
|
|
||||||
|
Execute (SetexToAtx):
|
||||||
|
:SetexToAtx
|
||||||
|
|
||||||
|
Expect (convert setex-style headings to atx):
|
||||||
|
# a
|
||||||
|
|
||||||
|
# a
|
||||||
|
|
||||||
|
## b
|
||||||
|
|
||||||
|
## b
|
||||||
|
|
||||||
|
Given markdown;
|
||||||
|
a
|
||||||
|
=
|
||||||
|
|
||||||
|
b
|
||||||
|
=
|
||||||
|
|
||||||
|
c
|
||||||
|
-
|
||||||
|
|
||||||
|
d
|
||||||
|
-
|
||||||
|
|
||||||
|
Execute (SetexToAtx with range):
|
||||||
|
:1,8SetexToAtx
|
||||||
|
|
||||||
|
Expect (only convert setex headings in original range):
|
||||||
|
# a
|
||||||
|
|
||||||
|
# b
|
||||||
|
|
||||||
|
## c
|
||||||
|
|
||||||
|
d
|
||||||
|
-
|
@ -2,6 +2,7 @@ Before:
|
|||||||
unlet! b:mkd_known_filetypes
|
unlet! b:mkd_known_filetypes
|
||||||
unlet! b:mkd_included_filetypes
|
unlet! b:mkd_included_filetypes
|
||||||
unlet! g:vim_markdown_math
|
unlet! g:vim_markdown_math
|
||||||
|
unlet! b:liquid_subtype
|
||||||
|
|
||||||
Given markdown;
|
Given markdown;
|
||||||
a **b** c
|
a **b** c
|
||||||
@ -855,6 +856,17 @@ a
|
|||||||
Execute (fenced code block with extended info strings):
|
Execute (fenced code block with extended info strings):
|
||||||
AssertEqual SyntaxOf('a'), 'mkdCode'
|
AssertEqual SyntaxOf('a'), 'mkdCode'
|
||||||
|
|
||||||
|
Given liquid;
|
||||||
|
```vim
|
||||||
|
let g:a = 1
|
||||||
|
```
|
||||||
|
|
||||||
|
Execute (fenced code block syntax in liquid file with markdown subtype):
|
||||||
|
let b:liquid_subtype = 'markdown'
|
||||||
|
let b:func = Markdown_GetFunc('vim-markdown/ftplugin/markdown.vim', 'MarkdownRefreshSyntax')
|
||||||
|
call b:func(0)
|
||||||
|
AssertEqual SyntaxOf('g:a'), 'vimVar'
|
||||||
|
|
||||||
# Code Blocks in pre and code tag
|
# Code Blocks in pre and code tag
|
||||||
|
|
||||||
Given markdown;
|
Given markdown;
|
||||||
|
@ -2,7 +2,7 @@ GEM
|
|||||||
remote: https://rubygems.org/
|
remote: https://rubygems.org/
|
||||||
specs:
|
specs:
|
||||||
diff-lcs (1.2.5)
|
diff-lcs (1.2.5)
|
||||||
rake (12.3.3)
|
rake (10.4.2)
|
||||||
rspec (3.4.0)
|
rspec (3.4.0)
|
||||||
rspec-core (~> 3.4.0)
|
rspec-core (~> 3.4.0)
|
||||||
rspec-expectations (~> 3.4.0)
|
rspec-expectations (~> 3.4.0)
|
||||||
|
@ -371,11 +371,11 @@ snippet != "Not Equal" w
|
|||||||
\neq
|
\neq
|
||||||
endsnippet
|
endsnippet
|
||||||
|
|
||||||
snippet <= "leq" Aw
|
snippet <= "leq" w
|
||||||
\le
|
\le
|
||||||
endsnippet
|
endsnippet
|
||||||
|
|
||||||
snippet >= "geq" Aw
|
snippet >= "geq" w
|
||||||
\ge
|
\ge
|
||||||
endsnippet
|
endsnippet
|
||||||
|
|
||||||
|
@ -68,5 +68,5 @@ snippet fwrs
|
|||||||
io.${1:stderr}:write("$0")
|
io.${1:stderr}:write("$0")
|
||||||
snippet fwrf
|
snippet fwrf
|
||||||
io.${1:stderr}:write(string.format("${2:%s}"$0))
|
io.${1:stderr}:write(string.format("${2:%s}"$0))
|
||||||
snippet im
|
snippet req
|
||||||
import "${1:import file}"
|
require('${1:mod}')
|
||||||
|
@ -70,6 +70,13 @@ support:
|
|||||||
git clone https://tpope.io/vim/surround.git
|
git clone https://tpope.io/vim/surround.git
|
||||||
vim -u NONE -c "helptags surround/doc" -c q
|
vim -u NONE -c "helptags surround/doc" -c q
|
||||||
|
|
||||||
|
## FAQ
|
||||||
|
|
||||||
|
> How do I surround without adding a space?
|
||||||
|
|
||||||
|
Only the opening brackets—`[`, `{`, and `(`—add a space. Use a closing
|
||||||
|
bracket, or the `b` (`(`) and `B` (`{`) aliases.
|
||||||
|
|
||||||
## Contributing
|
## Contributing
|
||||||
|
|
||||||
See the contribution guidelines for
|
See the contribution guidelines for
|
||||||
|
@ -7,11 +7,11 @@ except ImportError:
|
|||||||
futures = None
|
futures = None
|
||||||
|
|
||||||
import re
|
import re
|
||||||
import zipfile
|
|
||||||
import shutil
|
import shutil
|
||||||
import tempfile
|
import tempfile
|
||||||
import requests
|
import urllib.request
|
||||||
|
import zipfile
|
||||||
|
from io import BytesIO
|
||||||
from os import path
|
from os import path
|
||||||
|
|
||||||
# --- Globals ----------------------------------------------
|
# --- Globals ----------------------------------------------
|
||||||
@ -63,7 +63,6 @@ vim-indent-guides https://github.com/nathanaelkane/vim-indent-guides
|
|||||||
mru.vim https://github.com/vim-scripts/mru.vim
|
mru.vim https://github.com/vim-scripts/mru.vim
|
||||||
editorconfig-vim https://github.com/editorconfig/editorconfig-vim
|
editorconfig-vim https://github.com/editorconfig/editorconfig-vim
|
||||||
dracula https://github.com/dracula/vim
|
dracula https://github.com/dracula/vim
|
||||||
jedi-vim https://github.com/davidhalter/jedi-vim
|
|
||||||
""".strip()
|
""".strip()
|
||||||
|
|
||||||
GITHUB_ZIP = "%s/archive/master.zip"
|
GITHUB_ZIP = "%s/archive/master.zip"
|
||||||
@ -72,16 +71,12 @@ SOURCE_DIR = path.join(path.dirname(__file__), "sources_non_forked")
|
|||||||
|
|
||||||
|
|
||||||
def download_extract_replace(plugin_name, zip_path, temp_dir, source_dir):
|
def download_extract_replace(plugin_name, zip_path, temp_dir, source_dir):
|
||||||
temp_zip_path = path.join(temp_dir, plugin_name)
|
|
||||||
|
|
||||||
# Download and extract file in temp dir
|
# Download and extract file in temp dir
|
||||||
req = requests.get(zip_path)
|
with urllib.request.urlopen(zip_path) as req:
|
||||||
open(temp_zip_path, "wb").write(req.content)
|
zip_f = zipfile.ZipFile(BytesIO(req.read()))
|
||||||
|
zip_f.extractall(temp_dir)
|
||||||
|
content_disp = req.headers.get("Content-Disposition")
|
||||||
|
|
||||||
zip_f = zipfile.ZipFile(temp_zip_path)
|
|
||||||
zip_f.extractall(temp_dir)
|
|
||||||
|
|
||||||
content_disp = req.headers.get("Content-Disposition")
|
|
||||||
filename = re.findall("filename=(.+).zip", content_disp)[0]
|
filename = re.findall("filename=(.+).zip", content_disp)[0]
|
||||||
plugin_temp_path = path.join(temp_dir, path.join(temp_dir, filename))
|
plugin_temp_path = path.join(temp_dir, path.join(temp_dir, filename))
|
||||||
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
|
||||||
" Maintainer:
|
" Maintainer:
|
||||||
" Amir Salihefendic — @amix3k
|
" Amir Salihefendic - @amix3k
|
||||||
"
|
"
|
||||||
" Awesome_version:
|
" Awesome_version:
|
||||||
" Get this config, nice color schemes and lots of plugins!
|
" Get this config, nice color schemes and lots of plugins!
|
||||||
|
@ -211,4 +211,4 @@ let g:airline_skip_empty_sections = 1
|
|||||||
let g:indentLine_enabled = 1
|
let g:indentLine_enabled = 1
|
||||||
let g:indentLine_concealcursor = ''
|
let g:indentLine_concealcursor = ''
|
||||||
let g:indentLine_char = '┆'
|
let g:indentLine_char = '┆'
|
||||||
let g:indentLine_faster = 1
|
let g:indentLine_faster = 1
|
Loading…
Reference in New Issue
Block a user