Altered code for bash 3.2 compatibility, default bash on macOS

This commit is contained in:
Spuriosity1i 2021-03-09 22:07:31 +11:00 committed by Patrick Boettcher
parent ecaeea06bc
commit a07f9169af

View File

@ -7,7 +7,7 @@ set -e
arr=( "$@" )
input=${arr[-1]}
input=${arr[${#arr[@]}-1]}
unset 'arr[${#arr[@]}-1]'
${arr[@]} < $input