diff options
| author | zeertzjq <zeertzjq@outlook.com> | 2024-11-09 09:31:52 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-11-09 09:31:52 +0800 |
| commit | b7e1bbfb50c78352e31a6b27f430db3c8f4fbf1d (patch) | |
| tree | bd284a9d68f1c0f83d7bdf50fc2924d3003f9265 /runtime/compiler/ruff.vim | |
| parent | 5a27d02584656f35d757c01f10a1d3c88910c519 (diff) | |
| parent | c914ecf4c930f247123ec40ffc4b59461cd1a1f2 (diff) | |
| download | rneovim-b7e1bbfb50c78352e31a6b27f430db3c8f4fbf1d.tar.gz rneovim-b7e1bbfb50c78352e31a6b27f430db3c8f4fbf1d.tar.bz2 rneovim-b7e1bbfb50c78352e31a6b27f430db3c8f4fbf1d.zip | |
Merge pull request #31130 from zeertzjq/vim-3780c11
vim-patch: runtime file updates
Diffstat (limited to 'runtime/compiler/ruff.vim')
| -rw-r--r-- | runtime/compiler/ruff.vim | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/runtime/compiler/ruff.vim b/runtime/compiler/ruff.vim new file mode 100644 index 0000000000..11a69740d8 --- /dev/null +++ b/runtime/compiler/ruff.vim @@ -0,0 +1,19 @@ +" Vim compiler file +" Compiler: Ruff (Python linter) +" Maintainer: @pbnj-dragon +" Last Change: 2024 Nov 07 + +if exists("current_compiler") | finish | endif +let current_compiler = "ruff" + +let s:cpo_save = &cpo +set cpo&vim + +" CompilerSet makeprg=ruff +let &l:makeprg= 'ruff check --output-format=concise ' + \ ..get(b:, 'ruff_makeprg_params', get(g:, 'ruff_makeprg_params', '--preview')) +exe 'CompilerSet makeprg='..escape(&l:makeprg, ' "') +CompilerSet errorformat=%f:%l:%c:\ %m,%f:%l:\ %m,%f:%l:%c\ -\ %m,%f: + +let &cpo = s:cpo_save +unlet s:cpo_save |