From e83f5ea2e775498fdd8307e6eb4c3436452699eb Mon Sep 17 00:00:00 2001 From: Amir Date: Sun, 21 Jun 2020 11:50:44 -0400 Subject: [PATCH] Updated plugins --- .../dockerfile/dockerfile_lint.vim | 19 ++++- .../ale/ale_linters/go/revive.vim | 21 +++++ .../ale/ale_linters/java/eclipselsp.vim | 19 +++++ .../ale/ale_linters/java/javac.vim | 35 +++++++- sources_non_forked/ale/autoload/ale.vim | 2 +- .../ale/doc/ale-cloudformation.txt | 36 ++++++++- sources_non_forked/ale/doc/ale-go.txt | 19 +++++ sources_non_forked/ale/doc/ale-java.txt | 37 ++++++++- .../doc/ale-supported-languages-and-tools.txt | 1 + sources_non_forked/ale/doc/ale.txt | 1 + sources_non_forked/ale/supported-tools.md | 1 + .../ctrlp.vim/autoload/ctrlp.vim | 22 ++++- sources_non_forked/goyo.vim/autoload/goyo.vim | 2 +- .../lightline.vim/.github/workflows/ci.yaml | 1 + .../lightline.vim/autoload/lightline.vim | 40 +++++----- .../lightline/colorscheme/jellybeans.vim | 2 +- .../lightline/colorscheme/seoul256.vim | 2 +- .../lightline/colorscheme/srcery_drk.vim | 2 +- .../autoload/lightline/colorscheme/wombat.vim | 4 +- .../autoload/lightline/colortable.vim | 12 ++- .../lightline.vim/test/autocmd.vim | 23 ++++++ sources_non_forked/nerdtree/CHANGELOG.md | 7 ++ .../nerdtree/autoload/nerdtree.vim | 2 +- .../nerdtree/lib/nerdtree/creator.vim | 6 +- .../nerdtree/lib/nerdtree/opener.vim | 2 +- .../nerdtree/lib/nerdtree/path.vim | 40 ++++++---- .../nerdtree/lib/nerdtree/tree_dir_node.vim | 1 + .../nerdtree/nerdtree_plugin/fs_menu.vim | 15 ++++ .../nerdtree/syntax/nerdtree.vim | 2 +- sources_non_forked/nginx.vim/syntax/nginx.vim | 3 + sources_non_forked/rust.vim/syntax/rust.vim | 29 ++++++- .../vim-fugitive/autoload/fugitive.vim | 80 ++++++++++++------- .../vim-fugitive/syntax/fugitive.vim | 10 ++- .../vim-gitgutter/autoload/gitgutter/hunk.vim | 33 +++++--- sources_non_forked/vim-gitgutter/unplace.vim | 27 ------- .../vim-javascript/ftdetect/javascript.vim | 2 +- .../vim-markdown/syntax/markdown.vim | 4 +- .../vim-markdown/test/syntax.vader | 3 +- .../vim-multiple-cursors/.travis.yml | 9 ++- .../vim-multiple-cursors/Gemfile.lock | 2 +- .../vim-multiple-cursors/README.md | 2 +- .../autoload/multiple_cursors.vim | 2 +- .../vim-snippets/UltiSnips/markdown.snippets | 2 +- .../vim-snippets/UltiSnips/rust.snippets | 10 ++- .../vim-snippets/snippets/html.snippets | 2 +- .../vim-snippets/snippets/rust.snippets | 26 ++++-- 46 files changed, 470 insertions(+), 152 deletions(-) create mode 100644 sources_non_forked/ale/ale_linters/go/revive.vim create mode 100644 sources_non_forked/lightline.vim/test/autocmd.vim delete mode 100644 sources_non_forked/vim-gitgutter/unplace.vim diff --git a/sources_non_forked/ale/ale_linters/dockerfile/dockerfile_lint.vim b/sources_non_forked/ale/ale_linters/dockerfile/dockerfile_lint.vim index 95768b12..0c0ad533 100644 --- a/sources_non_forked/ale/ale_linters/dockerfile/dockerfile_lint.vim +++ b/sources_non_forked/ale/ale_linters/dockerfile/dockerfile_lint.vim @@ -32,14 +32,29 @@ function! ale_linters#dockerfile#dockerfile_lint#Handle(buffer, lines) abort let l:line = get(l:object, 'line', -1) let l:message = l:object['message'] - if get(l:object, 'description', 'None') isnot# 'None' - let l:message = l:message . '. ' . l:object['description'] + let l:link = get(l:object, 'reference_url', '') + + if type(l:link) == v:t_list + " Somehow, reference_url is returned as two-part list. + " Anchor markers in that list are sometimes duplicated. + " See https://github.com/projectatomic/dockerfile_lint/issues/134 + let l:link = join(l:link, '') + let l:link = substitute(l:link, '##', '#', '') endif + let l:detail = l:message + + if get(l:object, 'description', 'None') isnot# 'None' + let l:detail .= "\n\n" . l:object['description'] + endif + + let l:detail .= "\n\n" . l:link + call add(l:messages, { \ 'lnum': l:line, \ 'text': l:message, \ 'type': ale_linters#dockerfile#dockerfile_lint#GetType(l:type), + \ 'detail': l:detail, \}) endfor endfor diff --git a/sources_non_forked/ale/ale_linters/go/revive.vim b/sources_non_forked/ale/ale_linters/go/revive.vim new file mode 100644 index 00000000..b14b5ab9 --- /dev/null +++ b/sources_non_forked/ale/ale_linters/go/revive.vim @@ -0,0 +1,21 @@ +" Author: Penghui Liao +" Description: Adds support for revive + +call ale#Set('go_revive_executable', 'revive') +call ale#Set('go_revive_options', '') + +function! ale_linters#go#revive#GetCommand(buffer) abort + let l:options = ale#Var(a:buffer, 'go_revive_options') + + return ale#go#EnvString(a:buffer) . '%e' + \ . (!empty(l:options) ? ' ' . l:options : '') + \ . ' %t' +endfunction + +call ale#linter#Define('go', { +\ 'name': 'revive', +\ 'output_stream': 'both', +\ 'executable': {b -> ale#Var(b, 'go_revive_executable')}, +\ 'command': function('ale_linters#go#revive#GetCommand'), +\ 'callback': 'ale#handlers#unix#HandleAsWarning', +\}) diff --git a/sources_non_forked/ale/ale_linters/java/eclipselsp.vim b/sources_non_forked/ale/ale_linters/java/eclipselsp.vim index 2648893b..2bfec043 100644 --- a/sources_non_forked/ale/ale_linters/java/eclipselsp.vim +++ b/sources_non_forked/ale/ale_linters/java/eclipselsp.vim @@ -7,6 +7,7 @@ call ale#Set('java_eclipselsp_path', ale#path#Simplify($HOME . '/eclipse.jdt.ls' call ale#Set('java_eclipselsp_config_path', '') call ale#Set('java_eclipselsp_workspace_path', '') call ale#Set('java_eclipselsp_executable', 'java') +call ale#Set('java_eclipselsp_javaagent', '') function! ale_linters#java#eclipselsp#Executable(buffer) abort return ale#Var(a:buffer, 'java_eclipselsp_executable') @@ -100,12 +101,30 @@ function! ale_linters#java#eclipselsp#WorkspacePath(buffer) abort return ale#path#Dirname(ale#java#FindProjectRoot(a:buffer)) endfunction +function! ale_linters#java#eclipselsp#Javaagent(buffer) abort + let l:rets = [] + let l:raw = ale#Var(a:buffer, 'java_eclipselsp_javaagent') + + if empty(l:raw) + return '' + endif + + let l:jars = split(l:raw) + + for l:jar in l:jars + call add(l:rets, ale#Escape('-javaagent:' . l:jar)) + endfor + + return join(l:rets, ' ') +endfunction + function! ale_linters#java#eclipselsp#Command(buffer, version) abort let l:path = ale#Var(a:buffer, 'java_eclipselsp_path') let l:executable = ale_linters#java#eclipselsp#Executable(a:buffer) let l:cmd = [ ale#Escape(l:executable), + \ ale_linters#java#eclipselsp#Javaagent(a:buffer), \ '-Declipse.application=org.eclipse.jdt.ls.core.id1', \ '-Dosgi.bundles.defaultStartLevel=4', \ '-Declipse.product=org.eclipse.jdt.ls.core.product', diff --git a/sources_non_forked/ale/ale_linters/java/javac.vim b/sources_non_forked/ale/ale_linters/java/javac.vim index 8bb52c0b..f866eb09 100644 --- a/sources_non_forked/ale/ale_linters/java/javac.vim +++ b/sources_non_forked/ale/ale_linters/java/javac.vim @@ -6,6 +6,7 @@ let s:classpath_sep = has('unix') ? ':' : ';' call ale#Set('java_javac_executable', 'javac') call ale#Set('java_javac_options', '') call ale#Set('java_javac_classpath', '') +call ale#Set('java_javac_sourcepath', '') function! ale_linters#java#javac#RunWithImportPaths(buffer) abort let l:command = '' @@ -40,10 +41,15 @@ endfunction function! s:BuildClassPathOption(buffer, import_paths) abort " Filter out lines like [INFO], etc. let l:class_paths = filter(a:import_paths[:], 'v:val !~# ''[''') - call extend( - \ l:class_paths, - \ split(ale#Var(a:buffer, 'java_javac_classpath'), s:classpath_sep), - \) + let l:cls_path = ale#Var(a:buffer, 'java_javac_classpath') + + if !empty(l:cls_path) && type(l:cls_path) is v:t_string + call extend(l:class_paths, split(l:cls_path, s:classpath_sep)) + endif + + if !empty(l:cls_path) && type(l:cls_path) is v:t_list + call extend(l:class_paths, l:cls_path) + endif return !empty(l:class_paths) \ ? '-cp ' . ale#Escape(join(l:class_paths, s:classpath_sep)) @@ -79,6 +85,27 @@ function! ale_linters#java#javac#GetCommand(buffer, import_paths, meta) abort endif endif + let l:source_paths = [] + let l:source_path = ale#Var(a:buffer, 'java_javac_sourcepath') + + if !empty(l:source_path) && type(l:source_path) is v:t_string + let l:source_paths = split(l:source_path, s:classpath_sep) + endif + + if !empty(l:source_path) && type(l:source_path) is v:t_list + let l:source_paths = l:source_path + endif + + if !empty(l:source_paths) + for l:path in l:source_paths + let l:sp_path = ale#path#FindNearestDirectory(a:buffer, l:path) + + if !empty(l:sp_path) + call add(l:sp_dirs, l:sp_path) + endif + endfor + endif + if !empty(l:sp_dirs) let l:sp_option = '-sourcepath ' \ . ale#Escape(join(l:sp_dirs, s:classpath_sep)) diff --git a/sources_non_forked/ale/autoload/ale.vim b/sources_non_forked/ale/autoload/ale.vim index 01e17b15..6251b47b 100644 --- a/sources_non_forked/ale/autoload/ale.vim +++ b/sources_non_forked/ale/autoload/ale.vim @@ -163,7 +163,7 @@ function! ale#Queue(delay, ...) abort endif endfunction -let s:current_ale_version = [2, 6, 0] +let s:current_ale_version = [2, 7, 0] " A function used to check for ALE features in files outside of the project. function! ale#Has(feature) abort diff --git a/sources_non_forked/ale/doc/ale-cloudformation.txt b/sources_non_forked/ale/doc/ale-cloudformation.txt index 59c6af06..9724403b 100644 --- a/sources_non_forked/ale/doc/ale-cloudformation.txt +++ b/sources_non_forked/ale/doc/ale-cloudformation.txt @@ -7,8 +7,40 @@ cfn-python-lint *ale-cloudformation-cfn-python-lint* cfn-python-lint is a linter for AWS CloudFormation template file. -https://github.com/awslabs/cfn-python-lint +Website: https://github.com/awslabs/cfn-python-lint +Installation +------------------------------------------------------------------------------- + + +Install cfn-python-lint using either pip or brew: > + +`pip install cfn-lint`. If pip is not available, run +`python setup.py clean --all` then `python setup.py install`. + + Homebrew (macOS): + +`brew install cfn-lint` + +< +Configuration +------------------------------------------------------------------------------- + +To get cloudformation linter to work on only CloudFormation files we must set +the buffer |filetype| to yaml.cloudformation. +This causes ALE to lint the file with linters configured for cloudformation and +yaml files. + +Just put: + +> + + au BufRead,BufNewFile *.template.yaml set filetype=yaml.cloudformation + +< + +on `ftdetect/cloudformation.vim` + +This will get both cloudformation and yaml linters to work on any file with `.template.yaml` ext. =============================================================================== vim:tw=78:ts=2:sts=2:sw=2:ft=help:norl: - diff --git a/sources_non_forked/ale/doc/ale-go.txt b/sources_non_forked/ale/doc/ale-go.txt index be53783e..5c0791bc 100644 --- a/sources_non_forked/ale/doc/ale-go.txt +++ b/sources_non_forked/ale/doc/ale-go.txt @@ -219,6 +219,25 @@ g:ale_go_govet_options *g:ale_go_govet_options* This variable can be set to pass additional options to the go vet linter. +=============================================================================== +revive *ale-go-revive* + +g:ale_go_revive_executable *g:ale_go_revive_executable* + *b:ale_go_revive_executable* + Type: |String| + Default: `'revive'` + + This variable can be set to change the revive executable path. + + +g:ale_go_revive_options *g:ale_go_revive_options* + *b:ale_go_revive_options* + Type: |String| + Default: `''` + + This variable can be set to pass additional options to the revive + + =============================================================================== staticcheck *ale-go-staticcheck* diff --git a/sources_non_forked/ale/doc/ale-java.txt b/sources_non_forked/ale/doc/ale-java.txt index 32f0e6eb..d2001ca7 100644 --- a/sources_non_forked/ale/doc/ale-java.txt +++ b/sources_non_forked/ale/doc/ale-java.txt @@ -46,7 +46,7 @@ javac *ale-java-javac* g:ale_java_javac_classpath *g:ale_java_javac_classpath* *b:ale_java_javac_classpath* - Type: |String| + Type: |String| or |List| Default: `''` This variable can be set to change the global classpath for Java. @@ -67,6 +67,30 @@ g:ale_java_javac_options *g:ale_java_javac_options* This variable can be set to pass additional options to javac. +g:ale_java_javac_sourcepath *g:ale_java_javac_sourcepath* + *b:ale_java_javac_sourcepath* + Type: |String| or |List| + Default: `''` + +This variable can set multiple source code paths, the source code path is a +relative path (relative to the project root directory). + +Example: + +String type: +Note that the unix system separator is a colon(`:`) window system +is a semicolon(`;`). +> + let g:ale_java_javac_sourcepath = 'build/gen/source/xx/main:build/gen/source' +< +List type: +> + let g:ale_java_javac_sourcepath = [ + \ 'build/generated/source/querydsl/main', + \ 'target/generated-sources/source/querydsl/main' + \ ] +< + =============================================================================== google-java-format *ale-java-google-java-format* @@ -222,6 +246,17 @@ g:ale_java_eclipselsp_workspace_path *g:ale_java_eclipselsp_workspace_path* absolute path of the Eclipse workspace. If not set this value will be set to the parent folder of the project root. +g:ale_java_eclipselsp_javaagent *g:ale_java_eclipselsp_javaagent* + *b:ale_java_eclipselsp_javaagent* + + Type: |String| + Default: `''` + + A variable to add java agent for annotation processing such as Lombok. + If you have multiple java agent files, use space to separate them. For example: +> + let g:ale_java_eclipselsp_javaagent='/eclipse/lombok.jar /eclipse/jacoco.jar' +< =============================================================================== uncrustify *ale-java-uncrustify* diff --git a/sources_non_forked/ale/doc/ale-supported-languages-and-tools.txt b/sources_non_forked/ale/doc/ale-supported-languages-and-tools.txt index bd2d5b4a..45252294 100644 --- a/sources_non_forked/ale/doc/ale-supported-languages-and-tools.txt +++ b/sources_non_forked/ale/doc/ale-supported-languages-and-tools.txt @@ -164,6 +164,7 @@ Notes: * `gosimple`!! * `gotype`!! * `go vet`!! + * `revive`!! * `staticcheck`!! * GraphQL * `eslint` diff --git a/sources_non_forked/ale/doc/ale.txt b/sources_non_forked/ale/doc/ale.txt index 8d5b8820..724da57e 100644 --- a/sources_non_forked/ale/doc/ale.txt +++ b/sources_non_forked/ale/doc/ale.txt @@ -2379,6 +2379,7 @@ documented in additional help files. gometalinter..........................|ale-go-gometalinter| gopls.................................|ale-go-gopls| govet.................................|ale-go-govet| + revive................................|ale-go-revive| staticcheck...........................|ale-go-staticcheck| graphql.................................|ale-graphql-options| eslint................................|ale-graphql-eslint| diff --git a/sources_non_forked/ale/supported-tools.md b/sources_non_forked/ale/supported-tools.md index f6b26458..7d2f5287 100644 --- a/sources_non_forked/ale/supported-tools.md +++ b/sources_non_forked/ale/supported-tools.md @@ -173,6 +173,7 @@ formatting. * [gosimple](https://github.com/dominikh/go-tools/tree/master/cmd/gosimple) :warning: :floppy_disk: * [gotype](https://godoc.org/golang.org/x/tools/cmd/gotype) :warning: :floppy_disk: * [go vet](https://golang.org/cmd/vet/) :floppy_disk: + * [revive](https://github.com/mgechev/revive) :warning: :floppy_disk: * [staticcheck](https://github.com/dominikh/go-tools/tree/master/cmd/staticcheck) :warning: :floppy_disk: * GraphQL * [eslint](http://eslint.org/) diff --git a/sources_non_forked/ctrlp.vim/autoload/ctrlp.vim b/sources_non_forked/ctrlp.vim/autoload/ctrlp.vim index d1e23696..828a8c8d 100644 --- a/sources_non_forked/ctrlp.vim/autoload/ctrlp.vim +++ b/sources_non_forked/ctrlp.vim/autoload/ctrlp.vim @@ -790,6 +790,9 @@ fu! s:BuildPrompt(upd) if empty(prt[1]) && s:focus exe 'echoh' hibase '| echon "_" | echoh None' en + if a:upd + cal s:NotifySearch() + en endf " - SetDefTxt() {{{1 fu! s:SetDefTxt() @@ -2609,6 +2612,10 @@ fu! ctrlp#clearmarkedlist() let s:marked = {} endf +fu! ctrlp#input() + retu s:getinput() +endf + fu! ctrlp#exit() cal s:PrtExit() endf @@ -2735,8 +2742,21 @@ fu! ctrlp#init(type, ...) en cal s:BuildPrompt(1) if s:keyloop | cal s:KeyLoop() | en - return 1 + retu 1 endf + +" - Events {{{1 +fu! s:NotifySearch() + let l:cb = s:getextvar('search') + if l:cb != -1 + cal eval(l:cb) + en +endf + +fu! ctrlp#update() + cal s:ForceUpdate() +endf + " - Autocmds {{{1 if has('autocmd') aug CtrlPAug diff --git a/sources_non_forked/goyo.vim/autoload/goyo.vim b/sources_non_forked/goyo.vim/autoload/goyo.vim index 6667620e..0593f78c 100644 --- a/sources_non_forked/goyo.vim/autoload/goyo.vim +++ b/sources_non_forked/goyo.vim/autoload/goyo.vim @@ -203,7 +203,7 @@ function! s:goyo_on(dim) endif " vim-signify - let t:goyo_disabled_signify = exists('b:sy') && b:sy.active + let t:goyo_disabled_signify = !empty(getbufvar(bufnr(''), 'sy')) if t:goyo_disabled_signify SignifyToggle endif diff --git a/sources_non_forked/lightline.vim/.github/workflows/ci.yaml b/sources_non_forked/lightline.vim/.github/workflows/ci.yaml index 967fbb2e..b5db7cef 100644 --- a/sources_non_forked/lightline.vim/.github/workflows/ci.yaml +++ b/sources_non_forked/lightline.vim/.github/workflows/ci.yaml @@ -13,6 +13,7 @@ jobs: strategy: matrix: vim: + - v8.2.1000 - v8.2.0000 - v8.1.0000 - v8.0.0000 diff --git a/sources_non_forked/lightline.vim/autoload/lightline.vim b/sources_non_forked/lightline.vim/autoload/lightline.vim index 0e5d401a..e85e5891 100644 --- a/sources_non_forked/lightline.vim/autoload/lightline.vim +++ b/sources_non_forked/lightline.vim/autoload/lightline.vim @@ -2,7 +2,7 @@ " Filename: autoload/lightline.vim " Author: itchyny " License: MIT License -" Last Change: 2020/03/16 19:10:15. +" Last Change: 2020/06/19 11:08:46. " ============================================================================= let s:save_cpo = &cpo @@ -11,27 +11,35 @@ set cpo&vim let s:_ = 1 " 1: uninitialized, 2: disabled function! lightline#update() abort - if &buftype ==# 'popup' | return | endif + if s:skip() | return | endif if s:_ if s:_ == 2 | return | endif call lightline#init() call lightline#colorscheme() endif - if !s:lightline.enable.statusline - return + if s:lightline.enable.statusline + let w = winnr() + let s = winnr('$') == 1 && w > 0 ? [lightline#statusline(0)] : [lightline#statusline(0), lightline#statusline(1)] + for n in range(1, winnr('$')) + call setwinvar(n, '&statusline', s[n!=w]) + endfor endif - let w = winnr() - let s = winnr('$') == 1 && w > 0 ? [lightline#statusline(0)] : [lightline#statusline(0), lightline#statusline(1)] - for n in range(1, winnr('$')) - call setwinvar(n, '&statusline', s[n!=w]) - endfor endfunction +if exists('*win_gettype') + function! s:skip() abort " Vim 8.2.0257 (00f3b4e007), 8.2.0991 (0fe937fd86), 8.2.0996 (40a019f157) + return win_gettype() ==# 'popup' || win_gettype() ==# 'autocmd' + endfunction +else + function! s:skip() abort + return &buftype ==# 'popup' + endfunction +endif + function! lightline#update_disable() abort - if !s:lightline.enable.statusline - return + if s:lightline.enable.statusline + call setwinvar(0, '&statusline', '') endif - call setwinvar(0, '&statusline', '') endfunction function! lightline#enable() abort @@ -190,13 +198,7 @@ function! lightline#colorscheme() abort let s:lightline.palette = g:lightline#colorscheme#{s:lightline.colorscheme}#palette finally if has('win32') && !has('gui_running') && &t_Co < 256 - for u in values(s:lightline.palette) - for v in values(u) - for _ in v - let [_[2], _[3]] = [lightline#colortable#gui2cui(_[0], _[2]), lightline#colortable#gui2cui(_[1], _[3])] - endfor - endfor - endfor + call lightline#colortable#gui2cui_palette(s:lightline.palette) endif let s:highlight = {} call lightline#highlight('normal') diff --git a/sources_non_forked/lightline.vim/autoload/lightline/colorscheme/jellybeans.vim b/sources_non_forked/lightline.vim/autoload/lightline/colorscheme/jellybeans.vim index 15b2b35b..262442a6 100644 --- a/sources_non_forked/lightline.vim/autoload/lightline/colorscheme/jellybeans.vim +++ b/sources_non_forked/lightline.vim/autoload/lightline/colorscheme/jellybeans.vim @@ -5,7 +5,7 @@ " Last Change: 2013/09/07 12:21:04. " ============================================================================= let s:base03 = [ '#151513', 233 ] -let s:base02 = [ '#30302c ', 236 ] +let s:base02 = [ '#30302c', 236 ] let s:base01 = [ '#4e4e43', 239 ] let s:base00 = [ '#666656', 242 ] let s:base0 = [ '#808070', 244 ] diff --git a/sources_non_forked/lightline.vim/autoload/lightline/colorscheme/seoul256.vim b/sources_non_forked/lightline.vim/autoload/lightline/colorscheme/seoul256.vim index ca2d5a09..8bc3e5dd 100644 --- a/sources_non_forked/lightline.vim/autoload/lightline/colorscheme/seoul256.vim +++ b/sources_non_forked/lightline.vim/autoload/lightline/colorscheme/seoul256.vim @@ -5,7 +5,7 @@ " Last Change: 2015/11/02 08:23:27. " ============================================================================= let s:base03 = [ '#151513', 233 ] -let s:base02 = [ '#30302c ', 236 ] +let s:base02 = [ '#30302c', 236 ] let s:base01 = [ '#4e4e43', 239 ] let s:base00 = [ '#666656', 242 ] let s:base0 = [ '#808070', 244 ] diff --git a/sources_non_forked/lightline.vim/autoload/lightline/colorscheme/srcery_drk.vim b/sources_non_forked/lightline.vim/autoload/lightline/colorscheme/srcery_drk.vim index f1c7e1dd..5aa3a8a9 100644 --- a/sources_non_forked/lightline.vim/autoload/lightline/colorscheme/srcery_drk.vim +++ b/sources_non_forked/lightline.vim/autoload/lightline/colorscheme/srcery_drk.vim @@ -5,7 +5,7 @@ " Last Change: 2018/05/19 " ============================================================================= let s:base03 = [ '#151513', 233 ] -let s:base02 = [ '#30302c ', 236 ] +let s:base02 = [ '#30302c', 236 ] let s:base01 = [ '#4e4e43', 239 ] let s:base00 = [ '#666656', 242 ] let s:base0 = [ '#808070', 244 ] diff --git a/sources_non_forked/lightline.vim/autoload/lightline/colorscheme/wombat.vim b/sources_non_forked/lightline.vim/autoload/lightline/colorscheme/wombat.vim index 96192476..9fee12e5 100644 --- a/sources_non_forked/lightline.vim/autoload/lightline/colorscheme/wombat.vim +++ b/sources_non_forked/lightline.vim/autoload/lightline/colorscheme/wombat.vim @@ -5,8 +5,8 @@ " Last Change: 2015/11/30 08:37:43. " ============================================================================= let s:base03 = [ '#242424', 235 ] -let s:base023 = [ '#353535 ', 236 ] -let s:base02 = [ '#444444 ', 238 ] +let s:base023 = [ '#353535', 236 ] +let s:base02 = [ '#444444', 238 ] let s:base01 = [ '#585858', 240 ] let s:base00 = [ '#666666', 242 ] let s:base0 = [ '#808080', 244 ] diff --git a/sources_non_forked/lightline.vim/autoload/lightline/colortable.vim b/sources_non_forked/lightline.vim/autoload/lightline/colortable.vim index 82617b20..6cdddd8d 100644 --- a/sources_non_forked/lightline.vim/autoload/lightline/colortable.vim +++ b/sources_non_forked/lightline.vim/autoload/lightline/colortable.vim @@ -2,7 +2,7 @@ " Filename: autoload/lightline/colortable.vim " Author: itchyny " License: MIT License -" Last Change: 2015/03/29 06:21:39. +" Last Change: 2020/06/19 11:07:13. " ============================================================================= let s:save_cpo = &cpo @@ -38,5 +38,15 @@ function! lightline#colortable#gui2cui(rgb, fallback) abort return rgb[0] + rgb[1] + rgb[2] endfunction +function! lightline#colortable#gui2cui_palette(palette) abort + for u in values(a:palette) + for v in values(u) + for w in v + let [w[2], w[3]] = [lightline#colortable#gui2cui(w[0], w[2]), lightline#colortable#gui2cui(w[1], w[3])] + endfor + endfor + endfor +endfunction + let &cpo = s:save_cpo unlet s:save_cpo diff --git a/sources_non_forked/lightline.vim/test/autocmd.vim b/sources_non_forked/lightline.vim/test/autocmd.vim new file mode 100644 index 00000000..934509b8 --- /dev/null +++ b/sources_non_forked/lightline.vim/test/autocmd.vim @@ -0,0 +1,23 @@ +if !has("patch-8.2.0996") + finish +endif + +let s:suite = themis#suite('autocmd') +let s:assert = themis#helper('assert') + +function! s:suite.before_each() + let g:lightline = {} + call lightline#init() + tabnew + tabonly +endfunction + +function! s:suite.doautoall() + tabnew + tabnew + tabprevious + doautoall WinEnter + let statusline = getwinvar(1, '&statusline') + call s:assert.match(statusline, 'lightline') + call s:assert.match(statusline, '_active_') +endfunction diff --git a/sources_non_forked/nerdtree/CHANGELOG.md b/sources_non_forked/nerdtree/CHANGELOG.md index 0bcf4d74..0f1f1f5e 100644 --- a/sources_non_forked/nerdtree/CHANGELOG.md +++ b/sources_non_forked/nerdtree/CHANGELOG.md @@ -4,7 +4,14 @@ version in an unordered list. The format is: - **.PATCH**: Pull Request Title (PR Author) [PR Number](Link to PR) --> +#### 6.8 +- **.0**: Allow concealed characters to show another character. (PhilRunninger) [#1138](https://github.com/preservim/nerdtree/pull/1138) #### 6.7 +- **.15**: Add curly braces to the list of characters to be escaped. (PhilRunninger) [#1128](https://github.com/preservim/nerdtree/pull/1128) +- **.14**: Use backward-compatible `nerdtree#and()` in one place that was missed. (PhilRunninger) [#1134](https://github.com/preservim/nerdtree/pull/1134) +- **.13**: `cmd.exe /c start "" ` for windows default viewer support. (J. AltayĆ³) [#1130](https://github.com/preservim/nerdtree/pull/1130) +- **.12**: Fixed a bug that caused the file-tree construction to slow down significantly. (Eugenij-W) [#1126](https://github.com/preservim/nerdtree/pull/1126) +- **.11**: Fix exception in NERDTreeFind (on windows OS and If the file is located in the root directory of the disk) (Eugenij-W) [#1122](https://github.com/preservim/nerdtree/pull/1122) - **.10**: Do not consider the tree root to be "cascadable". (lifecrisis) [#1120](https://github.com/preservim/nerdtree/pull/1120) - **.9**: Force `:NERDTreeFocus` to allow events to be fired when switching windows. (PhilRunninger) [#1118](https://github.com/preservim/nerdtree/pull/1118) - **.8**: Fix example code for the `NERDTreeAddKeyMap()` function. (PhilRunninger) [#1116](https://github.com/preservim/nerdtree/pull/1116) diff --git a/sources_non_forked/nerdtree/autoload/nerdtree.vim b/sources_non_forked/nerdtree/autoload/nerdtree.vim index 156b2602..d0785a4c 100644 --- a/sources_non_forked/nerdtree/autoload/nerdtree.vim +++ b/sources_non_forked/nerdtree/autoload/nerdtree.vim @@ -45,7 +45,7 @@ function! nerdtree#slash() abort endfunction "FUNCTION: nerdtree#and(x,y) {{{2 -" Implements and() function for Vim <= 7.2 +" Implements and() function for Vim <= 7.4 function! nerdtree#and(x,y) abort if exists('*and') return and(a:x, a:y) diff --git a/sources_non_forked/nerdtree/lib/nerdtree/creator.vim b/sources_non_forked/nerdtree/lib/nerdtree/creator.vim index abaa8dbe..f845361d 100644 --- a/sources_non_forked/nerdtree/lib/nerdtree/creator.vim +++ b/sources_non_forked/nerdtree/lib/nerdtree/creator.vim @@ -249,7 +249,11 @@ function! s:Creator._pathForString(str) if dir =~# '^\.' let dir = getcwd() . g:NERDTreePath.Slash() . dir endif - let dir = g:NERDTreePath.Resolve(dir) + + "hack to prevent removing slash if dir is the root of the file system. + if dir !=# '/' + let dir = g:NERDTreePath.Resolve(dir) + endif try let path = g:NERDTreePath.New(dir) diff --git a/sources_non_forked/nerdtree/lib/nerdtree/opener.vim b/sources_non_forked/nerdtree/lib/nerdtree/opener.vim index 0d9f9ba8..6cdd9dfc 100644 --- a/sources_non_forked/nerdtree/lib/nerdtree/opener.vim +++ b/sources_non_forked/nerdtree/lib/nerdtree/opener.vim @@ -219,7 +219,7 @@ endfunction " FUNCTION: Opener._openFile() {{{1 function! s:Opener._openFile() - if !self._stay && !and(g:NERDTreeQuitOnOpen,1) && exists('b:NERDTreeZoomed') && b:NERDTreeZoomed + if !self._stay && !nerdtree#and(g:NERDTreeQuitOnOpen,1) && exists('b:NERDTreeZoomed') && b:NERDTreeZoomed call b:NERDTree.ui.toggleZoom() endif diff --git a/sources_non_forked/nerdtree/lib/nerdtree/path.vim b/sources_non_forked/nerdtree/lib/nerdtree/path.vim index 2ac8c71c..d30dd511 100644 --- a/sources_non_forked/nerdtree/lib/nerdtree/path.vim +++ b/sources_non_forked/nerdtree/lib/nerdtree/path.vim @@ -332,7 +332,7 @@ function! s:Path._escChars() return " `\|\"#%&,?()\*^<>$" endif - return " \\`\|\"#%&,?()\*^<>[]$" + return " \\`\|\"#%&,?()\*^<>[]{}$" endfunction " FUNCTION: Path.getDir() {{{1 @@ -546,26 +546,36 @@ endfunction " return 1 if this path is somewhere above the given path in the filesystem. " " a:path should be a dir -function! s:Path.isAncestor(path) - if !self.isDirectory - return 0 - endif - - let this = self.str() - let that = a:path.str() - return stridx(that, this) ==# 0 +function! s:Path.isAncestor(child) + return a:child.isUnder(self) endfunction " FUNCTION: Path.isUnder(path) {{{1 " return 1 if this path is somewhere under the given path in the filesystem. -function! s:Path.isUnder(path) - if a:path.isDirectory ==# 0 +function! s:Path.isUnder(parent) + if a:parent.isDirectory ==# 0 return 0 endif - - let this = self.str() - let that = a:path.str() - return stridx(this, that . s:Path.Slash()) ==# 0 + if nerdtree#runningWindows() && a:parent.drive !=# self.drive + return 0 + endif + let l:this_count = len(self.pathSegments) + if l:this_count ==# 0 + return 0 + endif + let l:that_count = len(a:parent.pathSegments) + if l:that_count ==# 0 + return 1 + endif + if l:that_count >= l:this_count + return 0 + endif + for i in range(0, l:that_count-1) + if self.pathSegments[i] !=# a:parent.pathSegments[i] + return 0 + endif + endfor + return 1 endfunction " FUNCTION: Path.JoinPathStrings(...) {{{1 diff --git a/sources_non_forked/nerdtree/lib/nerdtree/tree_dir_node.vim b/sources_non_forked/nerdtree/lib/nerdtree/tree_dir_node.vim index 14d29964..d2ad1cd7 100644 --- a/sources_non_forked/nerdtree/lib/nerdtree/tree_dir_node.vim +++ b/sources_non_forked/nerdtree/lib/nerdtree/tree_dir_node.vim @@ -431,6 +431,7 @@ function! s:TreeDirNode._initChildren(silent) endtry endfor + let g:NERDTreeOldSortOrder = g:NERDTreeSortOrder call self.sortChildren() call nerdtree#echo('') diff --git a/sources_non_forked/nerdtree/nerdtree_plugin/fs_menu.vim b/sources_non_forked/nerdtree/nerdtree_plugin/fs_menu.vim index 9750976f..30734147 100644 --- a/sources_non_forked/nerdtree/nerdtree_plugin/fs_menu.vim +++ b/sources_non_forked/nerdtree/nerdtree_plugin/fs_menu.vim @@ -34,6 +34,10 @@ if executable('xdg-open') call NERDTreeAddMenuItem({'text': '(o)pen the current node with system editor', 'shortcut': 'o', 'callback': 'NERDTreeExecuteFileLinux'}) endif +if nerdtree#runningWindows() + call NERDTreeAddMenuItem({'text': '(o)pen the current node with system editor', 'shortcut': 'o', 'callback': 'NERDTreeExecuteFileWindows'}) +endif + if g:NERDTreePath.CopyingSupported() call NERDTreeAddMenuItem({'text': '(c)opy the current node', 'shortcut': 'c', 'callback': 'NERDTreeCopyNode'}) endif @@ -451,4 +455,15 @@ function! NERDTreeExecuteFileLinux() call system('xdg-open ' . shellescape(l:node.path.str())) endfunction +" FUNCTION: NERDTreeExecuteFileWindows() {{{1 +function! NERDTreeExecuteFileWindows() + let l:node = g:NERDTreeFileNode.GetSelected() + + if empty(l:node) + return + endif + + call system('cmd.exe /c start "" ' . shellescape(l:node.path.str())) +endfunction + " vim: set sw=4 sts=4 et fdm=marker: diff --git a/sources_non_forked/nerdtree/syntax/nerdtree.vim b/sources_non_forked/nerdtree/syntax/nerdtree.vim index df0c8046..fc7269ea 100644 --- a/sources_non_forked/nerdtree/syntax/nerdtree.vim +++ b/sources_non_forked/nerdtree/syntax/nerdtree.vim @@ -22,7 +22,7 @@ syn match NERDTreeLinkDir #.*/ ->#me=e-3 containedin=NERDTreeDir "highlighting to conceal the delimiter around the file/dir name if has('conceal') exec 'syn match NERDTreeNodeDelimiters #\%d' . char2nr(g:NERDTreeNodeDelimiter) . '# conceal containedin=ALL' - setlocal conceallevel=3 concealcursor=nvic + setlocal conceallevel=2 concealcursor=nvic else exec 'syn match NERDTreeNodeDelimiters #\%d' . char2nr(g:NERDTreeNodeDelimiter) . '# containedin=ALL' hi! link NERDTreeNodeDelimiters Ignore diff --git a/sources_non_forked/nginx.vim/syntax/nginx.vim b/sources_non_forked/nginx.vim/syntax/nginx.vim index 9e3b16b8..9d3b92e2 100644 --- a/sources_non_forked/nginx.vim/syntax/nginx.vim +++ b/sources_non_forked/nginx.vim/syntax/nginx.vim @@ -298,12 +298,15 @@ syn keyword ngxDirective large_client_header_buffers syn keyword ngxDirective least_conn syn keyword ngxDirective least_time syn keyword ngxDirective limit_conn +syn keyword ngxDirective limit_conn_dry_run syn keyword ngxDirective limit_conn_log_level syn keyword ngxDirective limit_conn_status syn keyword ngxDirective limit_conn_zone +syn keyword ngxDirective limit_except syn keyword ngxDirective limit_rate syn keyword ngxDirective limit_rate_after syn keyword ngxDirective limit_req +syn keyword ngxDirective limit_req_dry_run syn keyword ngxDirective limit_req_log_level syn keyword ngxDirective limit_req_status syn keyword ngxDirective limit_req_zone diff --git a/sources_non_forked/rust.vim/syntax/rust.vim b/sources_non_forked/rust.vim/syntax/rust.vim index 423e8fba..4677e211 100644 --- a/sources_non_forked/rust.vim/syntax/rust.vim +++ b/sources_non_forked/rust.vim/syntax/rust.vim @@ -67,8 +67,7 @@ syn keyword rustObsoleteExternMod mod contained nextgroup=rustIdentifier skipw syn match rustIdentifier contains=rustIdentifierPrime "\%([^[:cntrl:][:space:][:punct:][:digit:]]\|_\)\%([^[:cntrl:][:punct:][:space:]]\|_\)*" display contained syn match rustFuncName "\%([^[:cntrl:][:space:][:punct:][:digit:]]\|_\)\%([^[:cntrl:][:punct:][:space:]]\|_\)*" display contained -syn region rustMacroRepeat matchgroup=rustMacroRepeatDelimiters start="$(" end=")" contains=TOP nextgroup=rustMacroRepeatCount -syn match rustMacroRepeatCount ".\?[*+]" contained +syn region rustMacroRepeat matchgroup=rustMacroRepeatDelimiters start="$(" end="),\=[*+]" contains=TOP syn match rustMacroVariable "$\w\+" " Reserved (but not yet used) keywords {{{2 @@ -231,6 +230,27 @@ syn region rustCommentBlockDocNestError matchgroup=rustCommentBlockDocError star syn keyword rustTodo contained TODO FIXME XXX NB NOTE +" asm! macro {{{2 +syn region rustAsmMacro matchgroup=rustMacro start="\', '-tab', 'g') 'keepalt split' s:fnameescape(file) + set bufhidden=wipe + let s:edit_jobs[bufnr('')] = [a:state, a:job] + return 1 + endif +endfunction + function! s:RunReceive(state, job, data, ...) abort call add(a:state.log, a:data) let data = type(a:data) == type([]) ? join(a:data, "\n") : a:data @@ -2283,16 +2306,21 @@ function! s:RunReceive(state, job, data, ...) abort let data = remove(a:state, 'buffer') . data endif let escape = "\033]51;[^\007]*" - let a:state.buffer = matchstr(data, escape . "$\\|[\r\n]\\+$") - if len(a:state.buffer) - let data = strpart(data, 0, len(data) - len(a:state.buffer)) + let a:state.escape_buffer = matchstr(data, escape . '$') + if len(a:state.escape_buffer) + let data = strpart(data, 0, len(data) - len(a:state.escape_buffer)) endif let cmd = matchstr(data, escape . "\007")[5:-2] let data = substitute(data, escape . "\007", '', 'g') - echon substitute(data, "\r\\ze\n", '', 'g') if cmd =~# '^fugitive:' let a:state.request = strpart(cmd, 9) endif + let data = a:state.echo_buffer . data + let a:state.echo_buffer = matchstr(data, "[\r\n]\\+$") + if len(a:state.echo_buffer) + let data = strpart(data, 0, len(data) - len(a:state.echo_buffer)) + endif + echon substitute(data, "\r\\ze\n", '', 'g') endfunction function! s:RunSend(job, str) abort @@ -2314,7 +2342,7 @@ endif function! s:RunWait(state, job) abort let finished = 0 try - while get(a:state, 'request', '') !=# 'edit' && (type(a:job) == type(0) ? jobwait([a:job], 1)[0] == -1 : ch_status(a:job) !=# 'closed') + while get(a:state, 'request', '') !=# 'edit' && (type(a:job) == type(0) ? jobwait([a:job], 1)[0] == -1 : ch_status(a:job) !=# 'closed' || job_status(a:job) ==# 'run') if !exists('*jobwait') sleep 1m endif @@ -2341,13 +2369,7 @@ function! s:RunWait(state, job) abort endwhile sleep 1m echo - if get(a:state, 'request', '') == 'edit' - call remove(a:state, 'request') - let file = readfile(a:state.temp . '.edit')[0] - exe substitute(a:state.mods, '\', '-tab', 'g') 'keepalt split' s:fnameescape(file) - set bufhidden=wipe - let s:edit_jobs[bufnr('')] = [a:state, a:job] - endif + call s:RunEdit(a:state, a:job) let finished = 1 finally if !finished @@ -2538,7 +2560,14 @@ function! fugitive#Command(line1, line2, range, bang, mods, arg) abort endif endif if s:RunJobs() - let state = {'dir': dir, 'mods': s:Mods(a:mods), 'temp': tempname(), 'log': []} + let state = { + \ 'dir': dir, + \ 'mods': s:Mods(a:mods), + \ 'title': ':Git ' . a:arg, + \ 'echo_buffer': '', + \ 'escape_buffer': '', + \ 'log': [], + \ 'temp': tempname()} let state.pty = get(g:, 'fugitive_pty', has('unix') && (has('patch-8.0.0744') || has('nvim'))) if !state.pty let args = s:AskPassArgs(dir) + args @@ -3598,6 +3627,10 @@ function! s:DoToggleHeadHeader(value) abort call search('\C^index$', 'wc') endfunction +function! s:DoToggleHelpHeader(value) abort + exe 'help fugitive-map' +endfunction + function! s:DoStagePushHeader(value) abort let remote = matchstr(a:value, '\zs[^/]\+\ze/') if empty(remote) @@ -4157,14 +4190,13 @@ function! s:GrepSubcommand(line1, line2, range, bang, mods, options) abort let args = args[1:-1] endif let name_only = s:HasOpt(args, '-l', '--files-with-matches', '--name-only', '-L', '--files-without-match') - let title = [listnr < 0 ? ':Ggrep' : ':Glgrep'] + args if listnr > 0 exe listnr 'wincmd w' else call s:BlurStatus() endif redraw - call s:QuickfixCreate(listnr, {'title': (listnr < 0 ? ':Ggrep ' : ':Glgrep ') . s:fnameescape(args)}) + call s:QuickfixCreate(listnr, {'title': (listnr < 0 ? ':Git grep ' : ':0Git grep ') . s:fnameescape(args)}) let tempfile = tempname() let event = listnr < 0 ? 'grep-fugitive' : 'lgrep-fugitive' silent exe s:DoAutocmd('QuickFixCmdPre ' . event) @@ -4742,18 +4774,6 @@ function! fugitive#FetchComplete(A, L, P, ...) abort return s:CompleteSub('fetch', a:A, a:L, a:P, function('s:CompleteRemote'), a:000) endfunction -function! s:AskPassArgs(dir) abort - if (len($DISPLAY) || len($TERM_PROGRAM) || has('gui_running')) && fugitive#GitVersion(1, 8) && - \ empty($GIT_ASKPASS) && empty($SSH_ASKPASS) && empty(FugitiveConfigGetAll('core.askpass', a:dir)) - if s:executable(s:ExecPath() . '/git-gui--askpass') - return ['-c', 'core.askPass=' . s:ExecPath() . '/git-gui--askpass'] - elseif s:executable('ssh-askpass') - return ['-c', 'core.askPass=ssh-askpass'] - endif - endif - return [] -endfunction - function! s:Dispatch(bang, options) abort let dir = a:options.dir exe s:DirCheck(dir) @@ -4797,11 +4817,11 @@ endfunction augroup fugitive_diff autocmd! - autocmd BufWinLeave * + autocmd BufWinLeave * nested \ if s:can_diffoff(+expand('')) && s:diff_window_count() == 2 | \ call s:diffoff_all(s:Dir(+expand(''))) | \ endif - autocmd BufWinEnter * + autocmd BufWinEnter * nested \ if s:can_diffoff(+expand('')) && s:diff_window_count() == 1 | \ call s:diffoff() | \ endif @@ -6026,7 +6046,7 @@ function! fugitive#MapJumps(...) abort call s:Map('n', 'czP', ':Git stash pop --quiet stash@{=v:count}') call s:Map('n', 'czv', ':exe "Gedit" fugitive#RevParse("stash@{" . v:count . "}")', '') call s:Map('n', 'czw', ':Git stash --keep-index=v:count > 1 ? " --all" : v:count ? " --include-untracked" : ""') - call s:Map('n', 'czz', ':Git stash =v:count > 1 ? " --all" : v:count ? " --include-untracked" : ""') + call s:Map('n', 'czz', ':Git stash =v:count > 1 ? " --all" : v:count ? " --include-untracked" : ""') call s:Map('n', 'cz?', ':help fugitive_cz', '') call s:Map('n', 'co', ':Git checkout') diff --git a/sources_non_forked/vim-fugitive/syntax/fugitive.vim b/sources_non_forked/vim-fugitive/syntax/fugitive.vim index afc0c0bc..e84eba4e 100644 --- a/sources_non_forked/vim-fugitive/syntax/fugitive.vim +++ b/sources_non_forked/vim-fugitive/syntax/fugitive.vim @@ -8,6 +8,9 @@ syn spell notoplevel syn include @fugitiveDiff syntax/diff.vim syn match fugitiveHeader /^[A-Z][a-z][^:]*:/ nextgroup=fugitiveHash,fugitiveSymbolicRef skipwhite +syn match fugitiveBareHeader /^Bare:/ +syn match fugitiveHelpHeader /^Help:/ nextgroup=fugitiveHelpTag skipwhite +syn match fugitiveHelpTag /\S\+/ contained syn region fugitiveSection start=/^\%(.*(\d\+)$\)\@=/ contains=fugitiveHeading end=/^$/ syn cluster fugitiveSection contains=fugitiveSection @@ -20,8 +23,8 @@ syn match fugitiveDone /^done\>/ contained containedin=@fugitiveSection nextgrou syn match fugitiveStop /^stop\>/ contained containedin=@fugitiveSection nextgroup=fugitiveHash skipwhite syn match fugitiveModifier /^[MADRCU?]\{1,2} / contained containedin=@fugitiveSection syn match fugitiveSymbolicRef /\.\@!\%(\.\.\@!\|[^[:space:][:cntrl:]\:.]\)\+\.\@/ contained containedin=@fugitiveSection -syn match fugitiveHash /\<\x\{4,\}\>/ contained +syn match fugitiveHash /^\x\{4,\}\S\@!/ contained containedin=@fugitiveSection +syn match fugitiveHash /\S\@ ]*>" end=">" diff --git a/sources_non_forked/vim-markdown/test/syntax.vader b/sources_non_forked/vim-markdown/test/syntax.vader index 5ce94fc2..d6f5487e 100644 --- a/sources_non_forked/vim-markdown/test/syntax.vader +++ b/sources_non_forked/vim-markdown/test/syntax.vader @@ -634,7 +634,8 @@ Given markdown; Execute (link with url title): AssertEqual SyntaxOf('https://domain.tld'), 'mkdInlineURL' - AssertEqual SyntaxOf('https://domain.com'), 'mkdInlineURL' + AssertNotEqual SyntaxOf(']'), 'mkdInlineURL' + AssertEqual SyntaxOf('https://domain.com'), 'mkdURL' AssertNotEqual SyntaxOf('not_a_link'), 'mkdInlineURL' # Code Blocks diff --git a/sources_non_forked/vim-multiple-cursors/.travis.yml b/sources_non_forked/vim-multiple-cursors/.travis.yml index cfb198ab..98d432c2 100644 --- a/sources_non_forked/vim-multiple-cursors/.travis.yml +++ b/sources_non_forked/vim-multiple-cursors/.travis.yml @@ -1,11 +1,12 @@ -sudo: false +os: linux +dist: bionic language: ruby addons: apt: packages: - vim-gtk + - xvfb -before_script: - - "export DISPLAY=:99.0" - - "sh -e /etc/init.d/xvfb start" +script: + - xvfb-run bundle exec rake diff --git a/sources_non_forked/vim-multiple-cursors/Gemfile.lock b/sources_non_forked/vim-multiple-cursors/Gemfile.lock index 5e909c4a..e833b243 100644 --- a/sources_non_forked/vim-multiple-cursors/Gemfile.lock +++ b/sources_non_forked/vim-multiple-cursors/Gemfile.lock @@ -2,7 +2,7 @@ GEM remote: https://rubygems.org/ specs: diff-lcs (1.2.5) - rake (12.3.3) + rake (10.4.2) rspec (3.4.0) rspec-core (~> 3.4.0) rspec-expectations (~> 3.4.0) diff --git a/sources_non_forked/vim-multiple-cursors/README.md b/sources_non_forked/vim-multiple-cursors/README.md index 43dcfee8..7abe3f30 100644 --- a/sources_non_forked/vim-multiple-cursors/README.md +++ b/sources_non_forked/vim-multiple-cursors/README.md @@ -1,5 +1,5 @@ # vim-multiple-cursors -[![Build Status](https://travis-ci.org/terryma/vim-multiple-cursors.svg)](https://travis-ci.org/terryma/vim-multiple-cursors) +[![Build Status](https://travis-ci.org/terryma/vim-multiple-cursors.svg?branch=master)](https://travis-ci.org/github/terryma/vim-multiple-cursors) ## Contents - [About](#about) diff --git a/sources_non_forked/vim-multiple-cursors/autoload/multiple_cursors.vim b/sources_non_forked/vim-multiple-cursors/autoload/multiple_cursors.vim index cdc8d978..32a9aec3 100644 --- a/sources_non_forked/vim-multiple-cursors/autoload/multiple_cursors.vim +++ b/sources_non_forked/vim-multiple-cursors/autoload/multiple_cursors.vim @@ -1285,7 +1285,7 @@ function! s:wait_for_user_input(mode) call s:start_latency_measure() " Clears any echoes we might've added - normal! : + normal! : " add chars to s:char if it start like a special/quit key let is_special_key = 0 diff --git a/sources_non_forked/vim-snippets/UltiSnips/markdown.snippets b/sources_non_forked/vim-snippets/UltiSnips/markdown.snippets index b9962a10..72b9f8f7 100644 --- a/sources_non_forked/vim-snippets/UltiSnips/markdown.snippets +++ b/sources_non_forked/vim-snippets/UltiSnips/markdown.snippets @@ -136,7 +136,7 @@ endsnippet snippet detail "Disclosure" - ${1:summary>${2}}$0 + ${1:${2}}$0 endsnippet diff --git a/sources_non_forked/vim-snippets/UltiSnips/rust.snippets b/sources_non_forked/vim-snippets/UltiSnips/rust.snippets index 0e3db68e..b284f0a2 100644 --- a/sources_non_forked/vim-snippets/UltiSnips/rust.snippets +++ b/sources_non_forked/vim-snippets/UltiSnips/rust.snippets @@ -17,13 +17,13 @@ pub fn ${1:function_name}($2)${3/..*/ -> /}$3 { endsnippet snippet afn "async fn name(?) -> ? {}" -fn ${1:function_name}($2)${3/..*/ -> /}$3 { +async fn ${1:function_name}($2)${3/..*/ -> /}$3 { ${VISUAL}$0 } endsnippet snippet pafn "pub async fn name(?) -> ? {}" -pub fn ${1:function_name}($2)${3/..*/ -> /}$3 { +pub async fn ${1:function_name}($2)${3/..*/ -> /}$3 { ${VISUAL}$0 } endsnippet @@ -44,4 +44,10 @@ snippet .it ".iter()" i .iter()$0 endsnippet +snippet impl "Struct/Trait implementation" b +impl ${1:Type/Trait}${2: for ${3:Type}} { + $0 +} +endsnippet + # vim:ft=snippets: diff --git a/sources_non_forked/vim-snippets/snippets/html.snippets b/sources_non_forked/vim-snippets/snippets/html.snippets index 0410d223..bc42f944 100644 --- a/sources_non_forked/vim-snippets/snippets/html.snippets +++ b/sources_non_forked/vim-snippets/snippets/html.snippets @@ -175,7 +175,7 @@ snippet aside# ${0} snippet audio - snippet b ${0} snippet base diff --git a/sources_non_forked/vim-snippets/snippets/rust.snippets b/sources_non_forked/vim-snippets/snippets/rust.snippets index 98088b0f..66b3d3e4 100644 --- a/sources_non_forked/vim-snippets/snippets/rust.snippets +++ b/sources_non_forked/vim-snippets/snippets/rust.snippets @@ -122,6 +122,10 @@ snippet ife "if / else" } else { ${0} } +snippet ifl "if let (...)" + if let ${1:Some(${2})} = $3 { + ${0:${VISUAL}} + } snippet el "else" else { ${0:${VISUAL}} @@ -146,6 +150,10 @@ snippet wh "while loop" while ${1:condition} { ${0:${VISUAL}} } +snippet whl "while let (...)" + while let ${1:Some(${2})} = $3 { + ${0:${VISUAL}} + } snippet for "for ... in ... loop" for ${1:i} in ${2} { ${0} @@ -157,21 +165,21 @@ snippet fixme "FIXME comment" // FIXME: $0 # Struct snippet st "Struct definition" - struct ${1:`substitute(vim_snippets#Filename(), '\(_\|^\)\(.\)', '\u\2', 'g')`} { + struct ${1:`substitute(vim_snippets#Filename(), '\(_\|^\)\(.\)', '\u\2', 'g')`}${2:<${3:T}>} { ${0} } snippet impl "Struct/Trait implementation" - impl ${1:Type/Trait}${2: for ${3:Type}} { + impl$4 ${1:Type/Trait}${2: for ${3:Type}}${4:<${5:T}>} { ${0} } snippet stn "Struct with new constructor" - pub struct ${1:`substitute(vim_snippets#Filename(), '\(_\|^\)\(.\)', '\u\2', 'g')`} { + pub struct ${1:`substitute(vim_snippets#Filename(), '\(_\|^\)\(.\)', '\u\2', 'g')`}${2:<${3:T}>} { ${0} } - impl $1 { - pub fn new(${2}) -> Self { - $1 { ${3} } + impl$2 $1$2 { + pub fn new(${4}) -> Self { + $1 { ${5} } } } snippet ty "Type alias" @@ -190,7 +198,7 @@ snippet trait "Trait definition" ${0} } snippet drop "Drop trait implementation (destructor)" - impl Drop for ${1:Name} { + impl$2 Drop for ${1:Name}${2:<${3:T}>} { fn drop(&mut self) { ${0} } @@ -238,9 +246,11 @@ snippet macro "macro_rules!" b $3 ) } -snippet box "Box::new()" +snippet boxp "Box::new()" Box::new(${0:${VISUAL}}) snippet rc "Rc::new()" Rc::new(${0:${VISUAL}}) snippet unim "unimplemented!()" unimplemented!() +snippet use "use ...;" b + use ${1:std::${2:io}};