From dae1213e57da36aaa805425636d11712c746fe49 Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Sun, 28 Oct 2018 13:51:36 +0100 Subject: vim-patch:f0b03c4e98f8 Update runtime files https://github.com/vim/vim/commit/f0b03c4e98f8a7184d8b4a5d702cbcd602426923 Note: haskell changes were included in 942f3587c38a83cf6486a0b779765b54a1648493 --- runtime/ftplugin/vim.vim | 34 ++++++++++++++++++---------------- runtime/ftplugin/zimbu.vim | 8 +++++--- 2 files changed, 23 insertions(+), 19 deletions(-) (limited to 'runtime/ftplugin') diff --git a/runtime/ftplugin/vim.vim b/runtime/ftplugin/vim.vim index f34655f330..59ea349710 100644 --- a/runtime/ftplugin/vim.vim +++ b/runtime/ftplugin/vim.vim @@ -1,7 +1,7 @@ " Vim filetype plugin " Language: Vim " Maintainer: Bram Moolenaar -" Last Change: 2017 Nov 06 +" Last Change: 2017 Dec 05 " Only do this when not done yet for this buffer if exists("b:did_ftplugin") @@ -42,21 +42,23 @@ setlocal commentstring=\"%s " Prefer Vim help instead of manpages. setlocal keywordprg=:help -" Move around functions. -nnoremap [[ m':call search('^\s*fu\%[nction]\>', "bW") -vnoremap [[ m':exe "normal! gv"call search('^\s*fu\%[nction]\>', "bW") -nnoremap ]] m':call search('^\s*fu\%[nction]\>', "W") -vnoremap ]] m':exe "normal! gv"call search('^\s*fu\%[nction]\>', "W") -nnoremap [] m':call search('^\s*endf*\%[unction]\>', "bW") -vnoremap [] m':exe "normal! gv"call search('^\s*endf*\%[unction]\>', "bW") -nnoremap ][ m':call search('^\s*endf*\%[unction]\>', "W") -vnoremap ][ m':exe "normal! gv"call search('^\s*endf*\%[unction]\>', "W") - -" Move around comments -nnoremap ]" :call search('^\(\s*".*\n\)\@ -vnoremap ]" :exe "normal! gv"call search('^\(\s*".*\n\)\@ -nnoremap [" :call search('\%(^\s*".*\n\)\%(^\s*"\)\@!', "bW") -vnoremap [" :exe "normal! gv"call search('\%(^\s*".*\n\)\%(^\s*"\)\@!', "bW") +if !exists("no_plugin_maps") && !exists("no_vim_maps") + " Move around functions. + nnoremap [[ m':call search('^\s*fu\%[nction]\>', "bW") + vnoremap [[ m':exe "normal! gv"call search('^\s*fu\%[nction]\>', "bW") + nnoremap ]] m':call search('^\s*fu\%[nction]\>', "W") + vnoremap ]] m':exe "normal! gv"call search('^\s*fu\%[nction]\>', "W") + nnoremap [] m':call search('^\s*endf*\%[unction]\>', "bW") + vnoremap [] m':exe "normal! gv"call search('^\s*endf*\%[unction]\>', "bW") + nnoremap ][ m':call search('^\s*endf*\%[unction]\>', "W") + vnoremap ][ m':exe "normal! gv"call search('^\s*endf*\%[unction]\>', "W") + + " Move around comments + nnoremap ]" :call search('^\(\s*".*\n\)\@ + vnoremap ]" :exe "normal! gv"call search('^\(\s*".*\n\)\@ + nnoremap [" :call search('\%(^\s*".*\n\)\%(^\s*"\)\@!', "bW") + vnoremap [" :exe "normal! gv"call search('\%(^\s*".*\n\)\%(^\s*"\)\@!', "bW") +endif " Let the matchit plugin know what items can be matched. if exists("loaded_matchit") diff --git a/runtime/ftplugin/zimbu.vim b/runtime/ftplugin/zimbu.vim index 558aea7df0..24674776cb 100644 --- a/runtime/ftplugin/zimbu.vim +++ b/runtime/ftplugin/zimbu.vim @@ -1,7 +1,7 @@ " Vim filetype plugin file " Language: Zimbu " Maintainer: Bram Moolenaar -" Last Change: 2012 Sep 08 +" Last Change: 2017 Dec 05 " Only do this when not done yet for this buffer if exists("b:did_ftplugin") @@ -135,8 +135,10 @@ iabbr until GCUpperSpace("until") iabbr while GCUpperSpace("while") iabbr repeat GCUpper("repeat") -nnoremap [[ m`:call ZimbuGoStartBlock() -nnoremap ]] m`:call ZimbuGoEndBlock() +if !exists("no_plugin_maps") && !exists("no_zimbu_maps") + nnoremap [[ m`:call ZimbuGoStartBlock() + nnoremap ]] m`:call ZimbuGoEndBlock() +endif " Using a function makes sure the search pattern is restored func! ZimbuGoStartBlock() -- cgit From 8d743d02f229aeed600bbc9a15736ad9e7be9507 Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Sun, 28 Oct 2018 13:59:07 +0100 Subject: vim-patch:df980db69b83 update a few runtime files https://github.com/vim/vim/commit/df980db69b831381c37c3e2973a6eefa10df305c Note: omit hl-Terminal, Nvim has its own way of highlighting :terminal. --- runtime/ftplugin/cmake.vim | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 runtime/ftplugin/cmake.vim (limited to 'runtime/ftplugin') diff --git a/runtime/ftplugin/cmake.vim b/runtime/ftplugin/cmake.vim new file mode 100644 index 0000000000..e81cd4071c --- /dev/null +++ b/runtime/ftplugin/cmake.vim @@ -0,0 +1,16 @@ +" Vim filetype plugin +" Language: CMake +" Maintainer: Keith Smiley +" Last Change: 2017 Dec 24 + +" Only do this when not done yet for this buffer +if exists("b:did_ftplugin") + finish +endif + +" Don't load another plugin for this buffer +let b:did_ftplugin = 1 + +let b:undo_ftplugin = "setl commentstring<" + +setlocal commentstring=#\ %s -- cgit From 1a51524ad540da00736027313cd89747c86c1690 Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Sun, 28 Oct 2018 14:02:09 +0100 Subject: vim-patch:40962ec9c0e7 Update runtime files. https://github.com/vim/vim/commit/40962ec9c0e7b8699e101182b06ddd39dc0e1212 --- runtime/ftplugin/nsis.vim | 33 +++++++++++++++++++++++++++------ runtime/ftplugin/python.vim | 5 ++++- 2 files changed, 31 insertions(+), 7 deletions(-) (limited to 'runtime/ftplugin') diff --git a/runtime/ftplugin/nsis.vim b/runtime/ftplugin/nsis.vim index 949691bf6e..1a35127c86 100644 --- a/runtime/ftplugin/nsis.vim +++ b/runtime/ftplugin/nsis.vim @@ -1,22 +1,43 @@ " Vim ftplugin file -" Language: NSIS script -" Previous Maintainer: Nikolai Weibull -" Latest Revision: 2008-07-09 - -let s:cpo_save = &cpo -set cpo&vim +" Language: NSIS script +" Maintainer: Ken Takata +" URL: https://github.com/k-takata/vim-nsis +" Previous Maintainer: Nikolai Weibull +" Last Change: 2018-01-26 if exists("b:did_ftplugin") finish endif + +let s:cpo_save = &cpo +set cpo&vim + let b:did_ftplugin = 1 let b:undo_ftplugin = "setl com< cms< fo< def< inc<" + \ " | unlet! b:match_ignorecase b:match_words" setlocal comments=s1:/*,mb:*,ex:*/,b:#,:; commentstring=;\ %s setlocal formatoptions-=t formatoptions+=croql setlocal define=^\\s*!define\\%(\\%(utc\\)\\=date\\|math\\)\\= setlocal include=^\\s*!include\\%(/NONFATAL\\)\\= +if exists("loaded_matchit") + let b:match_ignorecase = 1 + let b:match_words = + \ '\${\%(If\|IfNot\|Unless\)}:\${\%(Else\|ElseIf\|ElseIfNot\|ElseUnless\)}:\${\%(EndIf\|EndUnless\)},' . + \ '\${Select}:\${EndSelect},' . + \ '\${Switch}:\${EndSwitch},' . + \ '\${\%(Do\|DoWhile\|DoUntil\)}:\${\%(Loop\|LoopWhile\|LoopUntil\)},' . + \ '\${\%(For\|ForEach\)}:\${Next},' . + \ '\:\,' . + \ '\:\,' . + \ '\:\,' . + \ '\:\,' . + \ '\${MementoSection}:\${MementoSectionEnd},' . + \ '!if\%(\%(macro\)\?n\?def\)\?\>:!else\>:!endif\>,' . + \ '!macro\>:!macroend\>' +endif + let &cpo = s:cpo_save unlet s:cpo_save diff --git a/runtime/ftplugin/python.vim b/runtime/ftplugin/python.vim index 54926418de..56f19cb323 100644 --- a/runtime/ftplugin/python.vim +++ b/runtime/ftplugin/python.vim @@ -3,7 +3,7 @@ " Maintainer: Tom Picton " Previous Maintainer: James Sully " Previous Maintainer: Johannes Zellner -" Last Change: Thur, 09 November 2017 +" Last Change: Wed, 20 December 2017 " https://github.com/tpict/vim-ftplugin-python if exists("b:did_ftplugin") | finish | endif @@ -20,6 +20,9 @@ setlocal comments=b:#,fb:- setlocal commentstring=#\ %s setlocal omnifunc=pythoncomplete#Complete +if has('python3') + setlocal omnifunc=python3complete#Complete +endif set wildignore+=*.pyc -- cgit From 733b4ce0339f2fdcdb0db67717fc090dcfecf250 Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Sun, 28 Oct 2018 14:05:39 +0100 Subject: vim-patch:7254067ee970 Update runtime files. https://github.com/vim/vim/commit/7254067ee970686cc3ff4a1effc3e49e9192a5c1 --- runtime/ftplugin/chicken.vim | 51 +++++++++++++++++++++++ runtime/ftplugin/debchangelog.vim | 6 +-- runtime/ftplugin/debcontrol.vim | 6 +-- runtime/ftplugin/scheme.vim | 85 +++++++++++++++++++++++---------------- 4 files changed, 108 insertions(+), 40 deletions(-) create mode 100644 runtime/ftplugin/chicken.vim (limited to 'runtime/ftplugin') diff --git a/runtime/ftplugin/chicken.vim b/runtime/ftplugin/chicken.vim new file mode 100644 index 0000000000..8daa04c774 --- /dev/null +++ b/runtime/ftplugin/chicken.vim @@ -0,0 +1,51 @@ +" CHICKEN-specific Vim customizations +" Last Change: 2018-01-06 +" Author: Evan Hanson +" Maintainer: Evan Hanson +" URL: https://foldling.org/vim/ftplugin/chicken.vim +" Notes: These are supplemental settings, to be loaded after the core +" Scheme ftplugin file (ftplugin/scheme.vim). Enable it by setting +" b:is_chicken=1 and filetype=scheme. + +if !exists('b:did_scheme_ftplugin') + finish +endif + +setl keywordprg=chicken-doc + +setl lispwords+=and-let* +setl lispwords+=begin-for-syntax +setl lispwords+=compiler-typecase +setl lispwords+=condition-case +setl lispwords+=define-compiler-syntax +setl lispwords+=define-constant +setl lispwords+=define-external +setl lispwords+=define-for-syntax +setl lispwords+=define-inline +setl lispwords+=define-record +setl lispwords+=define-record-printer +setl lispwords+=define-specialization +setl lispwords+=define-syntax-rule +setl lispwords+=eval-when +setl lispwords+=fluid-let +setl lispwords+=handle-exceptions +setl lispwords+=let-compiler-syntax +setl lispwords+=let-optionals +setl lispwords+=let-optionals* +setl lispwords+=letrec-values +setl lispwords+=match +setl lispwords+=match-lambda +setl lispwords+=match-lambda* +setl lispwords+=match-let +setl lispwords+=match-let* +setl lispwords+=module +setl lispwords+=receive +setl lispwords+=select +setl lispwords+=set!-values + +let b:undo_ftplugin = b:undo_ftplugin . ' keywordprg<' + +if exists('g:loaded_matchit') && !exists('b:match_words') + let b:match_words = '#>:<#' + let b:undo_ftplugin = b:undo_ftplugin . ' | unlet! b:match_words' +endif diff --git a/runtime/ftplugin/debchangelog.vim b/runtime/ftplugin/debchangelog.vim index d2718db88e..32f683109d 100644 --- a/runtime/ftplugin/debchangelog.vim +++ b/runtime/ftplugin/debchangelog.vim @@ -1,11 +1,11 @@ " Vim filetype plugin file (GUI menu, folding and completion) " Language: Debian Changelog -" Maintainer: Debian Vim Maintainers +" Maintainer: Debian Vim Maintainers " Former Maintainers: Michael Piefel " Stefano Zacchiroli -" Last Change: 2014-01-31 +" Last Change: 2018-01-06 " License: Vim License -" URL: http://hg.debian.org/hg/pkg-vim/vim/file/unstable/runtime/ftplugin/debchangelog.vim +" URL: https://salsa.debian.org/vim-team/vim-debian/blob/master/ftplugin/debchangelog.vim " Bug completion requires apt-listbugs installed for Debian packages or " python-launchpadlib installed for Ubuntu packages diff --git a/runtime/ftplugin/debcontrol.vim b/runtime/ftplugin/debcontrol.vim index 7871d9897f..9643d16c28 100644 --- a/runtime/ftplugin/debcontrol.vim +++ b/runtime/ftplugin/debcontrol.vim @@ -1,9 +1,9 @@ " Vim filetype plugin file (GUI menu and folding) " Language: Debian control files -" Maintainer: Debian Vim Maintainers +" Maintainer: Debian Vim Maintainers " Former Maintainer: Pierre Habouzit -" Last Change: 2008-03-08 -" URL: http://hg.debian.org/hg/pkg-vim/vim/raw-file/tip/runtime/ftplugin/debcontrol.vim +" Last Change: 2018-01-06 +" URL: https://salsa.debian.org/vim-team/vim-debian/blob/master/ftplugin/debcontrol.vim " Do these settings once per buffer if exists("b:did_ftplugin") diff --git a/runtime/ftplugin/scheme.vim b/runtime/ftplugin/scheme.vim index ab1543a5ee..b7f8e8bbe7 100644 --- a/runtime/ftplugin/scheme.vim +++ b/runtime/ftplugin/scheme.vim @@ -1,45 +1,62 @@ -" Vim filetype plugin -" Language: Scheme -" Maintainer: Sergey Khorev -" URL: http://sites.google.com/site/khorser/opensource/vim -" Original author: Dorai Sitaram -" Original URL: http://www.ccs.neu.edu/~dorai/vimplugins/vimplugins.html -" Last Change: Oct 23, 2013 - -" Only do this when not done yet for this buffer -if exists("b:did_ftplugin") +" Vim filetype plugin file +" Language: Scheme (R7RS) +" Last Change: 2018-01-20 +" Author: Evan Hanson +" Maintainer: Evan Hanson +" Previous Maintainer: Sergey Khorev +" URL: https://foldling.org/vim/ftplugin/scheme.vim + +if exists('b:did_ftplugin') finish endif -" Don't load another plugin for this buffer -let b:did_ftplugin = 1 +let s:cpo = &cpo +set cpo&vim -" Copy-paste from ftplugin/lisp.vim -setl comments=:; -setl define=^\\s*(def\\k* -setl formatoptions-=t -setl iskeyword+=+,-,*,/,%,<,=,>,:,$,?,!,@-@,94 setl lisp +setl comments=:;;;;,:;;;,:;;,:;,sr:#\|,ex:\|# setl commentstring=;%s +setl define=^\\s*(def\\k* +setl iskeyword=33,35-39,42-43,45-58,60-90,94,95,97-122,126 -setl comments^=:;;;,:;;,sr:#\|,mb:\|,ex:\|# +let b:undo_ftplugin = 'setl lisp< comments< commentstring< define< iskeyword<' -" Scheme-specific settings -if exists("b:is_mzscheme") || exists("is_mzscheme") - " improve indenting - setl iskeyword+=#,%,^ - setl lispwords+=module,parameterize,let-values,let*-values,letrec-values - setl lispwords+=define-values,opt-lambda,case-lambda,syntax-rules,with-syntax,syntax-case - setl lispwords+=define-signature,unit,unit/sig,compund-unit/sig,define-values/invoke-unit/sig -endif +setl lispwords=begin +setl lispwords+=case +setl lispwords+=case-lambda +setl lispwords+=cond +setl lispwords+=cond-expand +setl lispwords+=define +setl lispwords+=define-record-type +setl lispwords+=define-syntax +setl lispwords+=define-values +setl lispwords+=do +setl lispwords+=guard +setl lispwords+=import +setl lispwords+=lambda +setl lispwords+=let +setl lispwords+=let* +setl lispwords+=let*-values +setl lispwords+=let-syntax +setl lispwords+=let-values +setl lispwords+=letrec +setl lispwords+=letrec* +setl lispwords+=letrec-syntax +setl lispwords+=parameterize +setl lispwords+=set! +setl lispwords+=syntax-rules +setl lispwords+=unless +setl lispwords+=when + +let b:undo_ftplugin = b:undo_ftplugin . ' lispwords<' -if exists("b:is_chicken") || exists("is_chicken") - " improve indenting - setl iskeyword+=#,%,^ - setl lispwords+=let-optionals,let-optionals*,declare - setl lispwords+=let-values,let*-values,letrec-values - setl lispwords+=define-values,opt-lambda,case-lambda,syntax-rules,with-syntax,syntax-case - setl lispwords+=cond-expand,and-let*,foreign-lambda,foreign-lambda* +let b:did_scheme_ftplugin = 1 + +if exists('b:is_chicken') || exists('g:is_chicken') + exe 'ru! ftplugin/chicken.vim' endif -let b:undo_ftplugin = "setlocal comments< define< formatoptions< iskeyword< lispwords< lisp< commentstring<" +unlet b:did_scheme_ftplugin +let b:did_ftplugin = 1 +let &cpo = s:cpo +unlet s:cpo -- cgit From c7513368f0e84da7ff3968c5b2912fa6ad15ab05 Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Mon, 29 Oct 2018 06:21:37 +0100 Subject: vim-patch:b5b7562475ad Update runtime files. https://github.com/vim/vim/commit/b5b7562475ad032a174b893286172de0d2c157cd --- NA patch (Nvim does not ship with spell files): vim-patch:3ad8772ef02e Include Serbian spell input files https://github.com/vim/vim/commit/3ad8772ef02e4352b0fa4e2697abc357734b62e1 --- runtime/ftplugin/chicken.vim | 17 ++++++++++------- runtime/ftplugin/scheme.vim | 11 +++-------- 2 files changed, 13 insertions(+), 15 deletions(-) (limited to 'runtime/ftplugin') diff --git a/runtime/ftplugin/chicken.vim b/runtime/ftplugin/chicken.vim index 8daa04c774..4dc1e57d0a 100644 --- a/runtime/ftplugin/chicken.vim +++ b/runtime/ftplugin/chicken.vim @@ -1,5 +1,5 @@ " CHICKEN-specific Vim customizations -" Last Change: 2018-01-06 +" Last Change: 2018-03-05 " Author: Evan Hanson " Maintainer: Evan Hanson " URL: https://foldling.org/vim/ftplugin/chicken.vim @@ -14,34 +14,37 @@ endif setl keywordprg=chicken-doc setl lispwords+=and-let* -setl lispwords+=begin-for-syntax setl lispwords+=compiler-typecase setl lispwords+=condition-case setl lispwords+=define-compiler-syntax setl lispwords+=define-constant setl lispwords+=define-external setl lispwords+=define-for-syntax +setl lispwords+=define-foreign-type setl lispwords+=define-inline +setl lispwords+=define-location setl lispwords+=define-record setl lispwords+=define-record-printer setl lispwords+=define-specialization -setl lispwords+=define-syntax-rule -setl lispwords+=eval-when setl lispwords+=fluid-let +setl lispwords+=foreign-lambda* +setl lispwords+=foreign-primitive +setl lispwords+=foreign-safe-lambda* +setl lispwords+=functor setl lispwords+=handle-exceptions setl lispwords+=let-compiler-syntax +setl lispwords+=let-location setl lispwords+=let-optionals setl lispwords+=let-optionals* setl lispwords+=letrec-values setl lispwords+=match -setl lispwords+=match-lambda -setl lispwords+=match-lambda* setl lispwords+=match-let setl lispwords+=match-let* +setl lispwords+=match-letrec setl lispwords+=module setl lispwords+=receive -setl lispwords+=select setl lispwords+=set!-values +setl lispwords+=test-group let b:undo_ftplugin = b:undo_ftplugin . ' keywordprg<' diff --git a/runtime/ftplugin/scheme.vim b/runtime/ftplugin/scheme.vim index b7f8e8bbe7..62fd327e07 100644 --- a/runtime/ftplugin/scheme.vim +++ b/runtime/ftplugin/scheme.vim @@ -1,6 +1,6 @@ " Vim filetype plugin file " Language: Scheme (R7RS) -" Last Change: 2018-01-20 +" Last Change: 2018-03-05 " Author: Evan Hanson " Maintainer: Evan Hanson " Previous Maintainer: Sergey Khorev @@ -14,25 +14,20 @@ let s:cpo = &cpo set cpo&vim setl lisp -setl comments=:;;;;,:;;;,:;;,:;,sr:#\|,ex:\|# +setl comments=:;;;;,:;;;,:;;,:;,sr:#\|,mb:\|,ex:\|# setl commentstring=;%s setl define=^\\s*(def\\k* setl iskeyword=33,35-39,42-43,45-58,60-90,94,95,97-122,126 let b:undo_ftplugin = 'setl lisp< comments< commentstring< define< iskeyword<' -setl lispwords=begin -setl lispwords+=case -setl lispwords+=case-lambda -setl lispwords+=cond -setl lispwords+=cond-expand +setl lispwords=case setl lispwords+=define setl lispwords+=define-record-type setl lispwords+=define-syntax setl lispwords+=define-values setl lispwords+=do setl lispwords+=guard -setl lispwords+=import setl lispwords+=lambda setl lispwords+=let setl lispwords+=let* -- cgit From 5c4a4217352edf82d32c03e6bec8c64b8f16a28c Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Mon, 29 Oct 2018 06:39:10 +0100 Subject: vim-patch:98ef233e14fa Update runtime files. Convert a couple of help files to utf-8. https://github.com/vim/vim/commit/98ef233e14faaaf42e0342da1803d493ce0337b2 --- runtime/ftplugin/python.vim | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) (limited to 'runtime/ftplugin') diff --git a/runtime/ftplugin/python.vim b/runtime/ftplugin/python.vim index 56f19cb323..ee271efaaf 100644 --- a/runtime/ftplugin/python.vim +++ b/runtime/ftplugin/python.vim @@ -3,7 +3,7 @@ " Maintainer: Tom Picton " Previous Maintainer: James Sully " Previous Maintainer: Johannes Zellner -" Last Change: Wed, 20 December 2017 +" Last Change: Sun, 18 March 2018 " https://github.com/tpict/vim-ftplugin-python if exists("b:did_ftplugin") | finish | endif @@ -14,7 +14,25 @@ set cpo&vim setlocal cinkeys-=0# setlocal indentkeys-=0# setlocal include=^\\s*\\(from\\\|import\\) -setlocal includeexpr=substitute(v:fname,'\\.','/','g') + +" For imports with leading .., append / and replace additional .s with ../ +let b:grandparent_match = '^\(.\.\)\(\.*\)' +let b:grandparent_sub = '\=submatch(1)."/".repeat("../",strlen(submatch(2)))' + +" For imports with a single leading ., replace it with ./ +let b:parent_match = '^\.\(\.\)\@!' +let b:parent_sub = './' + +" Replace any . sandwiched between word characters with / +let b:child_match = '\(\w\)\.\(\w\)' +let b:child_sub = '\1/\2' + +setlocal includeexpr=substitute(substitute(substitute( + \v:fname, + \b:grandparent_match,b:grandparent_sub,''), + \b:parent_match,b:parent_sub,''), + \b:child_match,b:child_sub,'g') + setlocal suffixesadd=.py setlocal comments=b:#,fb:- setlocal commentstring=#\ %s -- cgit From 9ef01272b23cffe98b5b19e34d05f1ac44cbeab1 Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Mon, 29 Oct 2018 08:27:28 +0100 Subject: vim-patch:7dda86f2ff35 Update runtime files. https://github.com/vim/vim/commit/7dda86f2ff35bb80afce4da24782fd58216bbe50 --- runtime/ftplugin/python.vim | 58 ++++++++++++++++++++++----------------------- 1 file changed, 29 insertions(+), 29 deletions(-) (limited to 'runtime/ftplugin') diff --git a/runtime/ftplugin/python.vim b/runtime/ftplugin/python.vim index ee271efaaf..5c4a59b1a9 100644 --- a/runtime/ftplugin/python.vim +++ b/runtime/ftplugin/python.vim @@ -3,7 +3,7 @@ " Maintainer: Tom Picton " Previous Maintainer: James Sully " Previous Maintainer: Johannes Zellner -" Last Change: Sun, 18 March 2018 +" Last Change: Sun, 15 April 2018 " https://github.com/tpict/vim-ftplugin-python if exists("b:did_ftplugin") | finish | endif @@ -53,35 +53,35 @@ let b:prev='\v^\s*(class\|def\|async def)>' let b:next_end='\v\S\n*(%$\|^(\s*\n*)*(class\|def\|async def)\|^\S)' let b:prev_end='\v\S\n*(^(\s*\n*)*(class\|def\|async def)\|^\S)' -execute "nnoremap ]] :call Python_jump('n', '". b:next_toplevel."', 'W')" -execute "nnoremap [[ :call Python_jump('n', '". b:prev_toplevel."', 'Wb')" -execute "nnoremap ][ :call Python_jump('n', '". b:next_endtoplevel."', 'W', 0)" -execute "nnoremap [] :call Python_jump('n', '". b:prev_endtoplevel."', 'Wb', 0)" -execute "nnoremap ]m :call Python_jump('n', '". b:next."', 'W')" -execute "nnoremap [m :call Python_jump('n', '". b:prev."', 'Wb')" -execute "nnoremap ]M :call Python_jump('n', '". b:next_end."', 'W', 0)" -execute "nnoremap [M :call Python_jump('n', '". b:prev_end."', 'Wb', 0)" - -execute "onoremap ]] :call Python_jump('o', '". b:next_toplevel."', 'W')" -execute "onoremap [[ :call Python_jump('o', '". b:prev_toplevel."', 'Wb')" -execute "onoremap ][ :call Python_jump('o', '". b:next_endtoplevel."', 'W', 0)" -execute "onoremap [] :call Python_jump('o', '". b:prev_endtoplevel."', 'Wb', 0)" -execute "onoremap ]m :call Python_jump('o', '". b:next."', 'W')" -execute "onoremap [m :call Python_jump('o', '". b:prev."', 'Wb')" -execute "onoremap ]M :call Python_jump('o', '". b:next_end."', 'W', 0)" -execute "onoremap [M :call Python_jump('o', '". b:prev_end."', 'Wb', 0)" - -execute "xnoremap ]] :call Python_jump('x', '". b:next_toplevel."', 'W')" -execute "xnoremap [[ :call Python_jump('x', '". b:prev_toplevel."', 'Wb')" -execute "xnoremap ][ :call Python_jump('x', '". b:next_endtoplevel."', 'W', 0)" -execute "xnoremap [] :call Python_jump('x', '". b:prev_endtoplevel."', 'Wb', 0)" -execute "xnoremap ]m :call Python_jump('x', '". b:next."', 'W')" -execute "xnoremap [m :call Python_jump('x', '". b:prev."', 'Wb')" -execute "xnoremap ]M :call Python_jump('x', '". b:next_end."', 'W', 0)" -execute "xnoremap [M :call Python_jump('x', '". b:prev_end."', 'Wb', 0)" +execute "nnoremap ]] :call Python_jump('n', '". b:next_toplevel."', 'W', v:count1)" +execute "nnoremap [[ :call Python_jump('n', '". b:prev_toplevel."', 'Wb', v:count1)" +execute "nnoremap ][ :call Python_jump('n', '". b:next_endtoplevel."', 'W', 0, v:count1)" +execute "nnoremap [] :call Python_jump('n', '". b:prev_endtoplevel."', 'Wb', 0, v:count1)" +execute "nnoremap ]m :call Python_jump('n', '". b:next."', 'W', v:count1)" +execute "nnoremap [m :call Python_jump('n', '". b:prev."', 'Wb', v:count1)" +execute "nnoremap ]M :call Python_jump('n', '". b:next_end."', 'W', 0, v:count1)" +execute "nnoremap [M :call Python_jump('n', '". b:prev_end."', 'Wb', 0, v:count1)" + +execute "onoremap ]] :call Python_jump('o', '". b:next_toplevel."', 'W', v:count1)" +execute "onoremap [[ :call Python_jump('o', '". b:prev_toplevel."', 'Wb', v:count1)" +execute "onoremap ][ :call Python_jump('o', '". b:next_endtoplevel."', 'W', 0, v:count1)" +execute "onoremap [] :call Python_jump('o', '". b:prev_endtoplevel."', 'Wb', 0, v:count1)" +execute "onoremap ]m :call Python_jump('o', '". b:next."', 'W', v:count1)" +execute "onoremap [m :call Python_jump('o', '". b:prev."', 'Wb', v:count1)" +execute "onoremap ]M :call Python_jump('o', '". b:next_end."', 'W', 0, v:count1)" +execute "onoremap [M :call Python_jump('o', '". b:prev_end."', 'Wb', 0, v:count1)" + +execute "xnoremap ]] :call Python_jump('x', '". b:next_toplevel."', 'W', v:count1)" +execute "xnoremap [[ :call Python_jump('x', '". b:prev_toplevel."', 'Wb', v:count1)" +execute "xnoremap ][ :call Python_jump('x', '". b:next_endtoplevel."', 'W', 0, v:count1)" +execute "xnoremap [] :call Python_jump('x', '". b:prev_endtoplevel."', 'Wb', 0, v:count1)" +execute "xnoremap ]m :call Python_jump('x', '". b:next."', 'W', v:count1)" +execute "xnoremap [m :call Python_jump('x', '". b:prev."', 'Wb', v:count1)" +execute "xnoremap ]M :call Python_jump('x', '". b:next_end."', 'W', 0, v:count1)" +execute "xnoremap [M :call Python_jump('x', '". b:prev_end."', 'Wb', 0, v:count1)" if !exists('*Python_jump') - fun! Python_jump(mode, motion, flags, ...) range + fun! Python_jump(mode, motion, flags, count, ...) range let l:startofline = (a:0 >= 1) ? a:1 : 1 if a:mode == 'x' @@ -92,7 +92,7 @@ if !exists('*Python_jump') normal! 0 endif - let cnt = v:count1 + let cnt = a:count mark ' while cnt > 0 call search(a:motion, a:flags) -- cgit From c05b0d8ec7a29b29ca36a78041cb67eefc146b30 Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Mon, 29 Oct 2018 08:43:13 +0100 Subject: vim-patch:85eee130f44a Update runtime files. https://github.com/vim/vim/commit/85eee130f44a2201d88ca2aeff0af3b11dd75fa9 --- runtime/ftplugin/debchangelog.vim | 128 +++++++++++++++++++------------------- runtime/ftplugin/debcontrol.vim | 18 +++--- 2 files changed, 73 insertions(+), 73 deletions(-) (limited to 'runtime/ftplugin') diff --git a/runtime/ftplugin/debchangelog.vim b/runtime/ftplugin/debchangelog.vim index 32f683109d..a78f7811f1 100644 --- a/runtime/ftplugin/debchangelog.vim +++ b/runtime/ftplugin/debchangelog.vim @@ -3,20 +3,20 @@ " Maintainer: Debian Vim Maintainers " Former Maintainers: Michael Piefel " Stefano Zacchiroli -" Last Change: 2018-01-06 +" Last Change: 2018-01-28 " License: Vim License " URL: https://salsa.debian.org/vim-team/vim-debian/blob/master/ftplugin/debchangelog.vim " Bug completion requires apt-listbugs installed for Debian packages or " python-launchpadlib installed for Ubuntu packages -if exists("b:did_ftplugin") +if exists('b:did_ftplugin') finish endif let b:did_ftplugin=1 " {{{1 Local settings (do on every load) -if exists("g:debchangelog_fold_enable") +if exists('g:debchangelog_fold_enable') setlocal foldmethod=expr setlocal foldexpr=DebGetChangelogFold(v:lnum) setlocal foldtext=DebChangelogFoldText() @@ -28,10 +28,10 @@ setlocal tw=78 setlocal comments=f:* " Clean unloading -let b:undo_ftplugin = "setlocal tw< comments< foldmethod< foldexpr< foldtext<" +let b:undo_ftplugin = 'setlocal tw< comments< foldmethod< foldexpr< foldtext<' " }}}1 -if exists("g:did_changelog_ftplugin") +if exists('g:did_changelog_ftplugin') finish endif @@ -44,41 +44,41 @@ let g:did_changelog_ftplugin = 1 " Returns full name, either from $DEBFULLNAME or debianfullname. " TODO Is there a way to determine name from anywhere else? function FullName() - if exists("$DEBFULLNAME") + if exists('$DEBFULLNAME') return $DEBFULLNAME - elseif exists("g:debianfullname") + elseif exists('g:debianfullname') return g:debianfullname else - return "Your Name" + return 'Your Name' endif endfunction " Returns email address, from $DEBEMAIL, $EMAIL or debianemail. function Email() - if exists("$DEBEMAIL") + if exists('$DEBEMAIL') return $DEBEMAIL - elseif exists("$EMAIL") + elseif exists('$EMAIL') return $EMAIL - elseif exists("g:debianemail") + elseif exists('g:debianemail') return g:debianemail else - return "your@email.address" + return 'your@email.address' endif endfunction " Returns date in RFC822 format. function Date() let savelang = v:lc_time - execute "language time C" - let dateandtime = strftime("%a, %d %b %Y %X %z") - execute "language time " . savelang + execute 'language time C' + let dateandtime = strftime('%a, %d %b %Y %X %z') + execute 'language time ' . savelang return dateandtime endfunction function WarnIfNotUnfinalised() - if match(getline("."), " -- [[:alpha:]][[:alnum:].]")!=-1 + if match(getline('.'), ' -- [[:alpha:]][[:alnum:].]')!=-1 echohl WarningMsg - echo "The entry has not been unfinalised before editing." + echo 'The entry has not been unfinalised before editing.' echohl None return 1 endif @@ -86,10 +86,10 @@ function WarnIfNotUnfinalised() endfunction function Finalised() - let savelinenum = line(".") - normal 1G - call search("^ -- ") - if match(getline("."), " -- [[:alpha:]][[:alnum:].]")!=-1 + let savelinenum = line('.') + 1 + call search('^ -- ') + if match(getline('.'), ' -- [[:alpha:]][[:alnum:].]')!=-1 let returnvalue = 1 else let returnvalue = 0 @@ -109,54 +109,54 @@ function NewVersion() amenu disable Changelog.Unfinalise amenu enable Changelog.Finalise call append(0, substitute(getline(1), '-\([[:digit:]]\+\))', '-$$\1)', '')) - call append(1, "") - call append(2, "") - call append(3, " -- ") - call append(4, "") - call Urgency("low") - normal 1G0 - call search(")") - normal h - normal  + call append(1, '') + call append(2, '') + call append(3, ' -- ') + call append(4, '') + call Urgency('low') + normal! 1G0 + call search(')') + normal! h + normal!  call setline(1, substitute(getline(1), '-\$\$', '-', '')) - if exists("g:debchangelog_fold_enable") + if exists('g:debchangelog_fold_enable') foldopen endif call AddEntry() endfunction function AddEntry() - normal 1G - call search("^ -- ") - normal kk - call append(".", " * ") - normal jjj + 1 + call search('^ -- ') + .-2 + call append('.', ' * ') + .+3 let warn=WarnIfNotUnfinalised() - normal kk + .-2 if warn echohl MoreMsg - call input("Hit ENTER") + call input('Hit ENTER') echohl None endif startinsert! endfunction function CloseBug() - normal 1G - call search("^ -- ") + 1 + call search('^ -- ') let warn=WarnIfNotUnfinalised() - normal kk - call append(".", " * (closes: #" . input("Bug number to close: ") . ")") - normal j^ll + .-2 + call append('.', ' * (closes: #' . input('Bug number to close: ') . ')') + normal! j^ll startinsert endfunction function Distribution(dist) - call setline(1, substitute(getline(1), ') *\%(UNRELEASED\|\l\+\);', ") " . a:dist . ";", "")) + call setline(1, substitute(getline(1), ') *\%(UNRELEASED\|\l\+\);', ') ' . a:dist . ';', '')) endfunction function Urgency(urg) - call setline(1, substitute(getline(1), "urgency=.*$", "urgency=" . a:urg, "")) + call setline(1, substitute(getline(1), 'urgency=.*$', 'urgency=' . a:urg, '')) endfunction function UnfinaliseMenu() @@ -172,9 +172,9 @@ endfunction function Unfinalise() call UnfinaliseMenu() - normal 1G - call search("^ -- ") - call setline(".", " -- ") + 1 + call search('^ -- ') + call setline('.', ' -- ') endfunction function FinaliseMenu() @@ -190,9 +190,9 @@ endfunction function Finalise() call FinaliseMenu() - normal 1G - call search("^ -- ") - call setline(".", " -- " . FullName() . " <" . Email() . "> " . Date()) + 1 + call search('^ -- ') + call setline('.', ' -- ' . FullName() . ' <' . Email() . '> ' . Date()) endfunction @@ -239,7 +239,7 @@ function! s:getAuthor(zonestart, zoneend) let linepos = a:zoneend while linepos >= a:zonestart let line = getline(linepos) - if line =~ '^ --' + if line =~# '^ --' return substitute(line, '^ --\s*\([^<]\+\)\s*.*', '\1', '') endif let linepos -= 1 @@ -254,7 +254,7 @@ function! DebGetPkgSrcName(lineno) let pkgname = '' while lineidx > 0 let curline = getline(lineidx) - if curline =~ '^\S' + if curline =~# '^\S' let pkgname = matchlist(curline, '^\(\S\+\).*$')[1] break endif @@ -264,7 +264,7 @@ function! DebGetPkgSrcName(lineno) endfunction function! DebChangelogFoldText() - if v:folddashes == '-' " changelog entry fold + if v:folddashes ==# '-' " changelog entry fold return foldtext() . ' -- ' . s:getAuthor(v:foldstart, v:foldend) . ' ' endif return foldtext() @@ -272,19 +272,19 @@ endfunction function! DebGetChangelogFold(lnum) let line = getline(a:lnum) - if line =~ '^\w\+' + if line =~# '^\w\+' return '>1' " beginning of a changelog entry endif - if line =~ '^\s\+\[.*\]' + if line =~# '^\s\+\[.*\]' return '>2' " beginning of an author-specific chunk endif - if line =~ '^ --' + if line =~# '^ --' return '1' endif return '=' endfunction -if exists("g:debchangelog_fold_enable") +if exists('g:debchangelog_fold_enable') silent! foldopen! " unfold the entry the cursor is on (usually the first one) endif @@ -305,13 +305,13 @@ fun! DebCompleteBugs(findstart, base) let try_colidx = col('.') - 1 let colidx = -1 " default to no-completion-possible - while try_colidx > 0 && line[try_colidx - 1] =~ '\s\|\d\|#\|,\|:' + while try_colidx > 0 && line[try_colidx - 1] =~# '\s\|\d\|#\|,\|:' let try_colidx = try_colidx - 1 - if line[try_colidx] == '#' && colidx == -1 + if line[try_colidx] ==# '#' && colidx == -1 " found hash, where we complete from: let colidx = try_colidx - elseif line[try_colidx] == ':' - if try_colidx > 1 && strpart(line, try_colidx - 2, 3) =~ '\clp:' + elseif line[try_colidx] ==# ':' + if try_colidx > 1 && strpart(line, try_colidx - 2, 3) =~? '\clp:' let g:debchangelog_complete_mode = 'lp' endif break @@ -320,7 +320,7 @@ fun! DebCompleteBugs(findstart, base) return colidx else " return matches: let bug_lines = [] - if g:debchangelog_complete_mode == 'lp' + if g:debchangelog_complete_mode ==? 'lp' if ! has('python') echoerr 'vim must be built with Python support to use LP bug completion' return @@ -363,7 +363,7 @@ EOF for line in bug_lines let parts = matchlist(line, '^\s*\(#\S\+\)\s*-\s*\(.*\)$') " filter only those which match a:base: - if parts[1] !~ "^" . a:base + if parts[1] !~ '^' . a:base continue endif let completion = {} diff --git a/runtime/ftplugin/debcontrol.vim b/runtime/ftplugin/debcontrol.vim index 9643d16c28..3a6e39a682 100644 --- a/runtime/ftplugin/debcontrol.vim +++ b/runtime/ftplugin/debcontrol.vim @@ -2,17 +2,17 @@ " Language: Debian control files " Maintainer: Debian Vim Maintainers " Former Maintainer: Pierre Habouzit -" Last Change: 2018-01-06 +" Last Change: 2018-01-28 " URL: https://salsa.debian.org/vim-team/vim-debian/blob/master/ftplugin/debcontrol.vim " Do these settings once per buffer -if exists("b:did_ftplugin") +if exists('b:did_ftplugin') finish endif let b:did_ftplugin=1 " {{{1 Local settings (do on every load) -if exists("g:debcontrol_fold_enable") +if exists('g:debcontrol_fold_enable') setlocal foldmethod=expr setlocal foldexpr=DebControlFold(v:lnum) setlocal foldtext=DebControlFoldText() @@ -20,7 +20,7 @@ endif setlocal textwidth=0 " Clean unloading -let b:undo_ftplugin = "setlocal tw< foldmethod< foldexpr< foldtext<" +let b:undo_ftplugin = 'setlocal tw< foldmethod< foldexpr< foldtext<' " }}}1 @@ -32,7 +32,7 @@ function! s:getField(f, lnum) while line !~ '^'.a:f.':' let fwdsteps += 1 let line = getline(a:lnum + fwdsteps) - if line == '' + if line ==# '' return 'unknown' endif endwhile @@ -40,9 +40,9 @@ function! s:getField(f, lnum) endfunction function! DebControlFoldText() - if v:folddashes == '-' " debcontrol entry fold + if v:folddashes ==# '-' " debcontrol entry fold let type = substitute(getline(v:foldstart), ':.*', '', '') - if type == 'Source' + if type ==# 'Source' let ftext = substitute(foldtext(), ' *Source: *', ' ', '') return ftext . ' -- ' . s:getField('Maintainer', v:foldstart) . ' ' endif @@ -56,11 +56,11 @@ endfunction function! DebControlFold(l) " This is for not merging blank lines around folds to them - if getline(a:l) =~ '^Source:' + if getline(a:l) =~# '^Source:' return '>1' endif - if getline(a:l) =~ '^Package:' + if getline(a:l) =~# '^Package:' return '>1' endif -- cgit From bee8a0ae8c1301653a3f291dc1505fc72d24f2f0 Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Mon, 29 Oct 2018 09:18:30 +0100 Subject: vim-patch:7db25fed5de1 Update runtime files. https://github.com/vim/vim/commit/7db25fed5de1be922b8cbb0328149469606a0424 --- runtime/ftplugin/xml.vim | 33 +++++++++++++++++---------------- 1 file changed, 17 insertions(+), 16 deletions(-) (limited to 'runtime/ftplugin') diff --git a/runtime/ftplugin/xml.vim b/runtime/ftplugin/xml.vim index 236e870537..573a6ba441 100644 --- a/runtime/ftplugin/xml.vim +++ b/runtime/ftplugin/xml.vim @@ -1,8 +1,10 @@ " Vim filetype plugin file " Language: xml -" Maintainer: Dan Sharp -" Last Changed: 20 Jan 2009 -" URL: http://dwsharp.users.sourceforge.net/vim/ftplugin +" Maintainer: Christian Brabandt +" Last Changed: May 08th, 2018 +" Repository: https://github.com/chrisbra/vim-xml-ftplugin +" Previous Maintainer: Dan Sharp +" URL: http://dwsharp.users.sourceforge.net/vim/ftplugin if exists("b:did_ftplugin") | finish | endif let b:did_ftplugin = 1 @@ -10,16 +12,16 @@ let b:did_ftplugin = 1 " Make sure the continuation lines below do not cause problems in " compatibility mode. let s:save_cpo = &cpo -set cpo-=C +set cpo&vim setlocal commentstring= -setlocal comments=s: +" Remove the middlepart from the comments section, as this causes problems: +" https://groups.google.com/d/msg/vim_dev/x4GT-nqa0Kg/jvtRnEbtAnMJ +setlocal comments=s: setlocal formatoptions-=t -if !exists("g:ft_xml_autocomment") || (g:ft_xml_autocomment == 1) - setlocal formatoptions+=croql -endif - +setlocal formatoptions+=croql +setlocal formatexpr=xmlformat#Format() " XML: thanks to Johannes Zellner and Akbar Ibrahim " - case sensitive @@ -39,7 +41,6 @@ if exists("loaded_matchit") \ '<\@<=\%([^ \t>/]\+\)\%(\s\+[^/>]*\|$\):/>' endif -" " For Omni completion, by Mikolaj Machowski. if exists('&ofu') setlocal ofu=xmlcomplete#CompleteTags @@ -47,17 +48,17 @@ endif command! -nargs=+ XMLns call xmlcomplete#CreateConnection() command! -nargs=? XMLent call xmlcomplete#CreateEntConnection() - " Change the :browse e filter to primarily show xml-related files. -if has("gui_win32") +if (has("gui_win32") || has("gui_gtk")) && !exists("b:browsefilter") let b:browsefilter="XML Files (*.xml)\t*.xml\n" . - \ "DTD Files (*.dtd)\t*.dtd\n" . - \ "All Files (*.*)\t*.*\n" + \ "DTD Files (*.dtd)\t*.dtd\n" . + \ "XSD Files (*.xsd)\t*.xsd\n" . + \ "All Files (*.*)\t*.*\n" endif " Undo the stuff we changed. -let b:undo_ftplugin = "setlocal commentstring< comments< formatoptions<" . - \ " | unlet! b:match_ignorecase b:match_words b:browsefilter" +let b:undo_ftplugin = "setlocal commentstring< comments< formatoptions< formatexpr< " . + \ " | unlet! b:match_ignorecase b:match_words b:browsefilter" " Restore the saved compatibility options. let &cpo = s:save_cpo -- cgit From de682a4f9eb96c394e59a827612353aa98a08d07 Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Mon, 29 Oct 2018 09:40:20 +0100 Subject: vim-patch:fd35811ca528 Update runtime files, add Danish translations. https://github.com/vim/vim/commit/fd35811ca528de7612f9571bce20ef4c392fe5f7 --- runtime/ftplugin/vim.vim | 26 ++++++++++++++++++++++++-- 1 file changed, 24 insertions(+), 2 deletions(-) (limited to 'runtime/ftplugin') diff --git a/runtime/ftplugin/vim.vim b/runtime/ftplugin/vim.vim index 59ea349710..da27e35faf 100644 --- a/runtime/ftplugin/vim.vim +++ b/runtime/ftplugin/vim.vim @@ -14,8 +14,28 @@ let b:did_ftplugin = 1 let s:cpo_save = &cpo set cpo-=C -let b:undo_ftplugin = "setl fo< isk< com< tw< commentstring< keywordprg<" - \ . "| unlet! b:match_ignorecase b:match_words b:match_skip" +if !exists('*VimFtpluginUndo') + func VimFtpluginUndo() + setl fo< isk< com< tw< commentstring< keywordprg< + if exists(b:did_add_maps) + silent! nunmap [[' + silent! vunmap [[' + silent! nunmap ]]' + silent! vunmap ]]' + silent! nunmap []' + silent! vunmap []' + silent! nunmap ][' + silent! vunmap ][' + silent! nunmap ]"' + silent! vunmap ]"' + silent! nunmap ["' + silent! vunmap ["' + endif + unlet! b:match_ignorecase b:match_words b:match_skip b:did_add_maps + endfunc +endif + +let b:undo_ftplugin = "call VimFtpluginUndo()" " Set 'formatoptions' to break comment lines but not other lines, " and insert the comment leader when hitting or using "o". @@ -43,6 +63,8 @@ setlocal commentstring=\"%s setlocal keywordprg=:help if !exists("no_plugin_maps") && !exists("no_vim_maps") + let b:did_add_maps = 1 + " Move around functions. nnoremap [[ m':call search('^\s*fu\%[nction]\>', "bW") vnoremap [[ m':exe "normal! gv"call search('^\s*fu\%[nction]\>', "bW") -- cgit From 07fdbba9d0a5cce9d466c36fbbaa9fe1cdeb1428 Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Mon, 29 Oct 2018 09:50:39 +0100 Subject: vim-patch:91f84f6e11cd Update runtime files. https://github.com/vim/vim/commit/91f84f6e11cd879d43d651c0903d85bff95f0716 --- runtime/ftplugin/rst.vim | 32 +++++++++++++++++++++++++++----- 1 file changed, 27 insertions(+), 5 deletions(-) (limited to 'runtime/ftplugin') diff --git a/runtime/ftplugin/rst.vim b/runtime/ftplugin/rst.vim index e61213e7a5..9d737cde44 100644 --- a/runtime/ftplugin/rst.vim +++ b/runtime/ftplugin/rst.vim @@ -1,10 +1,12 @@ -" Vim filetype plugin file -" Language: reStructuredText documentation format -" Previous Maintainer: Nikolai Weibull -" Latest Revision: 2008-07-09 +" reStructuredText filetype plugin file +" Language: reStructuredText documentation format +" Maintainer: Marshall Ward +" Original Maintainer: Nikolai Weibull +" Website: https://github.com/marshallward/vim-restructuredtext +" Latest Revision: 2018-01-07 if exists("b:did_ftplugin") - finish + finish endif let b:did_ftplugin = 1 @@ -16,5 +18,25 @@ let b:undo_ftplugin = "setl com< cms< et< fo<" setlocal comments=fb:.. commentstring=..\ %s expandtab setlocal formatoptions+=tcroql +" reStructuredText standard recommends that tabs be expanded to 8 spaces +" The choice of 3-space indentation is to provide slightly better support for +" directives (..) and ordered lists (1.), although it can cause problems for +" many other cases. +" +" More sophisticated indentation rules should be revisted in the future. + +if !exists("g:rst_style") || g:rst_style != 0 + setlocal expandtab shiftwidth=3 softtabstop=3 tabstop=8 +endif + +if has('patch-7.3.867') " Introduced the TextChanged event. + setlocal foldmethod=expr + setlocal foldexpr=RstFold#GetRstFold() + setlocal foldtext=RstFold#GetRstFoldText() + augroup RstFold + autocmd TextChanged,InsertLeave unlet! b:RstFoldCache + augroup END +endif + let &cpo = s:cpo_save unlet s:cpo_save -- cgit From 4f67f5ba6e5c9c1a8483e2b1f5faaa48bfb221ad Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Mon, 29 Oct 2018 09:55:33 +0100 Subject: vim-patch:d2855f5454c5 Update runtime files. https://github.com/vim/vim/commit/d2855f5454c5c6c5f786b228c5b67757edfefcb1 --- runtime/ftplugin/wast.vim | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 runtime/ftplugin/wast.vim (limited to 'runtime/ftplugin') diff --git a/runtime/ftplugin/wast.vim b/runtime/ftplugin/wast.vim new file mode 100644 index 0000000000..0d9e98d37a --- /dev/null +++ b/runtime/ftplugin/wast.vim @@ -0,0 +1,17 @@ +" Vim filetype plugin file +" Language: WebAssembly +" Maintainer: rhysd +" Last Change: Jul 29, 2018 +" For bugs, patches and license go to https://github.com/rhysd/vim-wasm + +if exists("b:did_ftplugin") + finish +endif +let b:did_ftplugin = 1 + +setlocal comments=s:(;,e:;),:;; +setlocal commentstring=(;%s;) +setlocal formatoptions-=t +setlocal iskeyword+=$,.,/ + +let b:undo_ftplugin = "setlocal comments< commentstring< formatoptions< iskeyword<" -- cgit From 228bc4c416092eb2601329aa881915a565ee64d2 Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Mon, 29 Oct 2018 09:57:50 +0100 Subject: vim-patch:d473c8c10126 Update runtime files. https://github.com/vim/vim/commit/d473c8c101262702ea9eeb14907ee20a786942b2 --- runtime/ftplugin/logtalk.dict | 362 +++++++++++++++++++++++++++--------------- runtime/ftplugin/logtalk.vim | 5 +- runtime/ftplugin/vim.vim | 30 ++-- 3 files changed, 248 insertions(+), 149 deletions(-) (limited to 'runtime/ftplugin') diff --git a/runtime/ftplugin/logtalk.dict b/runtime/ftplugin/logtalk.dict index e3b9e6f2a4..3fcdfc6f6a 100644 --- a/runtime/ftplugin/logtalk.dict +++ b/runtime/ftplugin/logtalk.dict @@ -1,164 +1,262 @@ -encoding +abolish +abolish_category +abolish_events +abolish_object +abolish_protocol +abs +acos +acyclic_term +after +alias +always_true_or_false_goals +arg +asin +asserta +assertz +atan +atan2 +atom +atomic +atom_chars +atom_chars +atom_codes +atom_codes +atom_concat +atom_concat +atom_length +at_end_of_stream +bagof +before +built_in +call +callable calls +catch category +category_property +ceiling +char_code +char_conversion +clause +clean +close +code_prefix +coinduction +coinductive +compare +complements +complements +complements_object +compound +conforms_to_protocol +context +context_switching_calls +copy_term +cos +create_category +create_logtalk_flag +create_object +create_protocol +current_category +current_char_conversion +current_event +current_input +current_logtalk_flag +current_object +current_op +current_output +current_predicate +current_prolog_flag +current_protocol +debug +define_events +deprecated +discontiguous +div +domain_error +duplicated_directives dynamic +dynamic_declarations +elif +else +encoding +encoding_directive +endif end_category end_object end_protocol -info -initialization -object -protocol -synchronized -threaded -uses -alias -discontiguous -meta_predicate -mode -op -private -protected -public -current_object -current_protocol -current_category -object_property -protocol_property -category_property -create_object -create_protocol -create_category -abolish_object -abolish_protocol -abolish_category -complements -complements_object +engines +ensure_loaded +evaluation_error +events +existence_error +exp +expand_goal +expand_term +export extends +extends_category extends_object extends_protocol -extends_category +fail +false +findall +float +float_fractional_part +float_integer_part +floor +flush_output +forall +forward +functor +get_byte +get_char +get_code +goal_expansion +ground +halt +hook +if +ignore implements implements_protocol imports imports_category +include +info +initialization instantiates instantiates_class -specializes -specializes_class -abolish_events -current_event -define_events -logtalk_load +instantiation_error +integer +keysort +lambda_variables +log logtalk_compile logtalk_library_path -current_logtalk_flag -set_logtalk_flag -threaded_call -threaded_once -threaded_ignore -threaded_exit -threaded_peek -threaded_wait -threaded_notify -self -this -sender -parameter -before -after -phrase -expand_term -goal_expansion -term_expansion -true -fail -call -catch -throw -unify_with_occurs_check -var -atom -integer -float -atomic -compound +logtalk_load +logtalk_load_context +logtalk_make +logtalk_make_target_action +max +meta_non_terminal +meta_predicate +min +missing_directives +mod +mode +modules +multifile +nl nonvar number -arg -copy_term -functor -current_predicate -predicate_property -abolish -assertz -asserta -clause -retract -retractall -bagof -findall -forall -setof -current_input -current_output -set_input -set_output +numbervars +number_chars +number_chars +number_codes +number_codes +object +object_property +once +op open -close -flush_output -stream_property -at_end_of_stream -set_stream_position -get_char -get_code +optimize +parameter +peek_byte peek_char peek_code +permission_error +phrase +portability +predicate_property +private +prolog_compatible_version +prolog_compiler +prolog_dialect +prolog_loader +prolog_version +protected +protocol +protocol_property +public +put_byte put_char put_code -nl -get_byte -peek_byte -put_byte read read_term -write -writeq -write_canonical -atom_chars -atom_codes -atom_concat -number_chars -number_codes -current_op -char_conversion -current_char_conversion -once -repeat -atom_length -atom_concat -sub_atom -atom_chars -atom_codes -char_code -number_chars -number_codes -set_prolog_flag -current_prolog_flag -halt -abs -atan -ceiling -cos -exp -float_fractional_part -float_integer_part -floor -log -mod +redefined_built_ins +reexport +reload rem +repeat +report +representation_error +resource_error +retract +retractall round +scratch_directory +self +sender +setof +set_input +set_logtalk_flag +set_output +set_prolog_flag +set_stream_position sign sin +singleton_variables +sort +source_data +specializes +specializes_class sqrt +stream_property +subsumes_term +sub_atom +suspicious_calls +synchronized +syntax_error +system_error +tabling +tan +term_expansion +term_variables +this +threaded +threaded_call +threaded_engine +threaded_engine_create +threaded_engine_destroy +threaded_engine_fetch +threaded_engine_next +threaded_engine_next_reified +threaded_engine_post +threaded_engine_self +threaded_engine_yield +threaded_exit +threaded_ignore +threaded_notify +threaded_once +threaded_peek +threaded_wait +threads +throw +trivial_goal_fails +true truncate +type_error +undefined_predicates +underscore_variables +unify_with_occurs_check +unknown_entities +unknown_predicates +uses +use_module +var +version +write +writeq +write_canonical +xor diff --git a/runtime/ftplugin/logtalk.vim b/runtime/ftplugin/logtalk.vim index e71307a399..667907ce5f 100644 --- a/runtime/ftplugin/logtalk.vim +++ b/runtime/ftplugin/logtalk.vim @@ -1,7 +1,7 @@ " Logtalk filetype plugin file " Language: Logtalk " Maintainer: Paulo Moura -" Latest Revision: 2007-07-06 +" Latest Revision: 2018-08-03 if exists("b:did_ftplugin") finish @@ -10,9 +10,10 @@ let b:did_ftplugin = 1 let b:undo_ftplugin = "setl ts< sw< fdm< fdc< ai< dict<" -"setlocal ts=4 +setlocal ts=4 setlocal sw=4 setlocal fdm=syntax +setlocal fdn=10 setlocal fdc=2 setlocal autoindent setlocal dict=$VIMRUNTIME/ftplugin/logtalk.dict diff --git a/runtime/ftplugin/vim.vim b/runtime/ftplugin/vim.vim index da27e35faf..eb8061d84f 100644 --- a/runtime/ftplugin/vim.vim +++ b/runtime/ftplugin/vim.vim @@ -1,7 +1,7 @@ " Vim filetype plugin " Language: Vim " Maintainer: Bram Moolenaar -" Last Change: 2017 Dec 05 +" Last Change: 2018 Aug 07 " Only do this when not done yet for this buffer if exists("b:did_ftplugin") @@ -17,20 +17,20 @@ set cpo-=C if !exists('*VimFtpluginUndo') func VimFtpluginUndo() setl fo< isk< com< tw< commentstring< keywordprg< - if exists(b:did_add_maps) - silent! nunmap [[' - silent! vunmap [[' - silent! nunmap ]]' - silent! vunmap ]]' - silent! nunmap []' - silent! vunmap []' - silent! nunmap ][' - silent! vunmap ][' - silent! nunmap ]"' - silent! vunmap ]"' - silent! nunmap ["' - silent! vunmap ["' - endif + if exists('b:did_add_maps') + silent! nunmap [[ + silent! vunmap [[ + silent! nunmap ]] + silent! vunmap ]] + silent! nunmap [] + silent! vunmap [] + silent! nunmap ][ + silent! vunmap ][ + silent! nunmap ]" + silent! vunmap ]" + silent! nunmap [" + silent! vunmap [" + endif unlet! b:match_ignorecase b:match_words b:match_skip b:did_add_maps endfunc endif -- cgit