Merge pull request #40826 from zeertzjq/vim-9.2.0792

vim-patch: runtime file updates
This commit is contained in:
zeertzjq 2026-07-19 10:04:06 +08:00 committed by GitHub
commit d3c10c6b9c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 26 additions and 1 deletions

View File

@ -0,0 +1,11 @@
" Vim ftplugin file
" Language: Jinja
" Maintainer: Alejandro Sanchez
" Upstream: https://gitlab.com/HiPhish/jinja.vim
if exists("b:did_jinjaplugin")
finish
endif
setlocal commentstring={#\ %s\ #}
let b:undo_ftplugin = "setlocal com<"

View File

@ -1,7 +1,7 @@
" Creator: Charles E Campbell
" Previous Maintainer: Luca Saccarola <github.e41mv@aleeas.com>
" Maintainer: This runtime file is looking for a new maintainer.
" Last Change: 2026 Jul 17
" Last Change: 2026 Jul 18
" Copyright: Copyright (C) 2016 Charles E. Campbell {{{1
" Permission is hereby granted to use and distribute this code,
" with or without modifications, provided that this copyright
@ -571,6 +571,9 @@ function netrw#Explore(indx,dosplit,style,...)
endif
if starpat == 0 && a:indx >= 0
if dirname == ""
let dirname= curfiledir
endif
" [Explore Hexplore Vexplore Sexplore] [dirname]
if dirname =~# '^scp://' || dirname =~ '^ftp://'
call netrw#Nread(2,dirname)

View File

@ -910,4 +910,15 @@ func Test_netrw_open_backslash_file()
bw!
endfunc
" :Explore without a [dir] argument should open the dir of the current file
func Test_netrw_open_no_dir_arg()
let dir = tempname()
call mkdir(dir, 'pR')
call writefile([], dir . '/foo')
exe 'edit ' . dir . '/foo'
Explore
call assert_equal(fnamemodify(dir, ':p'), fnamemodify(b:netrw_curdir, ':p'))
bw!
endfunc
" vim:ts=8 sts=2 sw=2 et