Merge pull request #1224 from KlzXS/nmv_list_current

Updated .nmv to support current when NNN_LIST
This commit is contained in:
Arun 2021-11-08 13:34:39 +00:00 committed by GitHub
commit 1508874b5a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 4 deletions

View File

@ -51,7 +51,11 @@ else
findcmd="$findcmd ! -name \".*\""
fi
findcmd="$findcmd -print"
if [ -z "$NNN_LIST" ]; then
findcmd="$findcmd -print"
else
findcmd="$findcmd -printf "'"'"$NNN_LIST/%P\n"'"'
fi
arr=$(eval "$findcmd" | sort)
fi

View File

@ -7267,9 +7267,7 @@ nochange:
case SEL_RENAMEMUL:
endselection(TRUE);
setenv("INCLUDE_HIDDEN", xitoa(cfg.showhidden), 1);
setenv("NNN_LIST", listpath
? xitoa(is_prefix(path, listpath, xstrlen(listpath)))
: "0", 1);
setenv("NNN_LIST", listpath ? listroot : "", 1);
if (!(getutil(utils[UTIL_BASH])
&& plugscript(utils[UTIL_NMV], F_CLI))