Allow file-search to find absolute file paths

Remove initial / from the search term to allow file-search to find files defined by a full path.
This commit is contained in:
pghvlaans 2022-02-05 19:21:29 +09:00 committed by GitHub
parent b211490ee5
commit 3e54f67638
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -487,7 +487,7 @@ case "$CMD" in
echo -e ""
;;
file-search)
PATTERN=$(echo $ARG | sed -e 's/\+/\\\+/g' -e 's/\./\\\./g' -e 's/ /\|/g')
PATTERN=$(echo $ARG | sed -e 's/^\///g' -e 's/\+/\\\+/g' -e 's/\./\\\./g' -e 's/ /\|/g')
makelist $PATTERN
if [ "$LIST" = "" ]; then