Merge pull request #35909 from zeertzjq/vim-34747a1

vim-patch: doc updates
This commit is contained in:
zeertzjq
2025-09-25 07:12:32 +08:00
committed by GitHub
2 changed files with 8 additions and 6 deletions

View File

@@ -1342,12 +1342,14 @@ file picker: >
set findfunc=Find set findfunc=Find
func Find(arg, _) func Find(arg, _)
if get(s:, 'filescache', []) == [] if empty(s:filescache)
let s:filescache = systemlist( let s:filescache = globpath('.', '**', 1, 1)
\ 'find . -path "*/.git" -prune -o -type f -print') call filter(s:filescache, '!isdirectory(v:val)')
call map(s:filescache, "fnamemodify(v:val, ':.')")
endif endif
return a:arg == '' ? s:filescache : matchfuzzy(s:filescache, a:arg) return a:arg == '' ? s:filescache : matchfuzzy(s:filescache, a:arg)
endfunc endfunc
let s:filescache = []
autocmd CmdlineEnter : let s:filescache = [] autocmd CmdlineEnter : let s:filescache = []
The `:Grep` command searches for lines matching a pattern and updates the The `:Grep` command searches for lines matching a pattern and updates the
@@ -1358,8 +1360,8 @@ the `CmdlineLeavePre` autocmd from the next section): >
\ Grep call <SID>VisitFile() \ Grep call <SID>VisitFile()
func s:Grep(arglead, cmdline, cursorpos) func s:Grep(arglead, cmdline, cursorpos)
let cmd = $'grep -REIHns "{a:arglead}" --exclude-dir=.git if match(&grepprg, '\$\*') == -1 | let &grepprg .= ' $*' | endif
\ --exclude=".*"' let cmd = substitute(&grepprg, '\$\*', shellescape(escape(a:arglead, '\')), '')
return len(a:arglead) > 1 ? systemlist(cmd) : [] return len(a:arglead) > 1 ? systemlist(cmd) : []
endfunc endfunc

View File

@@ -8,7 +8,7 @@
" 2025 Sep 05 by Vim Project ensure netrw#fs#Dirname() returns trailing slash #18199 " 2025 Sep 05 by Vim Project ensure netrw#fs#Dirname() returns trailing slash #18199
" 2025 Sep 11 by Vim Project only keep cursor position in tree mode #18275 " 2025 Sep 11 by Vim Project only keep cursor position in tree mode #18275
" 2025 Sep 17 by Vim Project tighten the regex to handle remote compressed archives #18318 " 2025 Sep 17 by Vim Project tighten the regex to handle remote compressed archives #18318
" 2025 Sep 18 by Vim Project equalalwayse not always respected #18358 " 2025 Sep 18 by Vim Project 'equalalways' not always respected #18358
" Copyright: Copyright (C) 2016 Charles E. Campbell {{{1 " Copyright: Copyright (C) 2016 Charles E. Campbell {{{1
" Permission is hereby granted to use and distribute this code, " Permission is hereby granted to use and distribute this code,
" with or without modifications, provided that this copyright " with or without modifications, provided that this copyright