1
0
forked from aniani/vim

patch 8.2.0876: :pwd does not give a hint about the scope of the directory

Problem:    :pwd does not give a hint about the scope of the directory
Solution:   Make ":verbose pwd" show the scope. (Takuya Fujiwara, closes #5469)
This commit is contained in:
Bram Moolenaar
2020-06-01 16:26:19 +02:00
parent 6c9ba04280
commit 950587242c
4 changed files with 36 additions and 4 deletions

View File

@@ -1338,6 +1338,21 @@ present in 'cpoptions' and "!" is not used in the command.
*:pw* *:pwd* *E187*
:pw[d] Print the current directory name.
Also see |getcwd()|.
*:pwd-verbose*
When 'verbose' is non-zero, |:pwd| will also display
what scope the current directory was set. Example: >
" Set by :cd
:verbose pwd
[global] /path/to/current
" Set by :lcd
:verbose pwd
[window] /path/to/current
" Set by :tcd
:verbose pwd
[tabpage] /path/to/current
So long as no |:lcd| or |:tcd| command has been used, all windows share the
same current directory. Using a command to jump to another window doesn't