diff --git a/rmate b/rmate index ce696b2..3379d42 100755 --- a/rmate +++ b/rmate @@ -170,6 +170,7 @@ function canonicalize { echo "$result" } +shopt -s extglob while [[ "$1" != "" ]]; do case $1 in -) @@ -222,7 +223,7 @@ while [[ "$1" != "" ]]; do showusage exit 0 ;; - +[0-9][0-9]*) + \++([0-9])) selections+=(${1:1}) ;; *) @@ -237,6 +238,7 @@ while [[ "$1" != "" ]]; do shift done +shopt -u extglob if [[ "$host" = "auto" && "$SSH_CONNECTION" != "" ]]; then host=${SSH_CONNECTION%% *}