Drop basename in favor of Bash strings

Convert `var=$(basename $file)` to `var="${file##*/}"`
This commit is contained in:
John D Pell
2021-09-11 23:47:10 -07:00
parent dee55a03cc
commit 470341b23a
4 changed files with 18 additions and 16 deletions

View File

@@ -15,7 +15,7 @@ function time-machine-list-machines() {
local tmdest="$(time-machine-destination)/Backups.backupdb"
find "$tmdest" -maxdepth 1 -mindepth 1 -type d | grep -v "/\." | while read line ; do
echo "$(basename "$line")"
echo "${line##*/}"
done
}