This commit is contained in:
Luke Smith 2020-07-28 10:04:28 -04:00
parent 66e2a7a1ed
commit c29080a25e
No known key found for this signature in database
GPG Key ID: 4C50B54A911F6252
1 changed files with 1 additions and 1 deletions

2
lb
View File

@ -34,7 +34,7 @@ listandReturn() {
*) ls -rc "$1" | awk -F '/' '{print $NF}' | nl
read -erp "Pick an entry by number to $2, or press Ctrl-C to cancel. " number ;;
esac
chosen="$(ls -rc "$1" | nl | grep -w "$number" | awk '{print $2}')"
chosen="$(ls -rc "$1" | nl | grep -w " $number" | awk '{print $2}')"
basefile="$(basename "$chosen")" && base="${basefile%.*}"
}