mirror of
https://github.com/neovim/neovim.git
synced 2025-09-19 01:38:16 +00:00
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 vim/vim#5469)
950587242c
This commit is contained in:
@@ -7845,7 +7845,17 @@ static void ex_pwd(exarg_T *eap)
|
||||
#ifdef BACKSLASH_IN_FILENAME
|
||||
slash_adjust(NameBuff);
|
||||
#endif
|
||||
msg(NameBuff);
|
||||
if (p_verbose > 0) {
|
||||
char *context = "global";
|
||||
if (curwin->w_localdir != NULL) {
|
||||
context = "window";
|
||||
} else if (curtab->tp_localdir != NULL) {
|
||||
context = "tabpage";
|
||||
}
|
||||
smsg("[%s] %s", context, (char *)NameBuff);
|
||||
} else {
|
||||
msg(NameBuff);
|
||||
}
|
||||
} else {
|
||||
EMSG(_("E187: Unknown"));
|
||||
}
|
||||
|
Reference in New Issue
Block a user