# # # patch "contrib/mtnopt" # from [56bfc9d39d09333ffaf27e487f569d53331ea453] # to [e34dea12d781e96b3e60658bdfc326829a52a9d5] # ============================================================ --- contrib/mtnopt 56bfc9d39d09333ffaf27e487f569d53331ea453 +++ contrib/mtnopt e34dea12d781e96b3e60658bdfc326829a52a9d5 @@ -7,7 +7,7 @@ usage () { values_only=/bin/false usage () { - echo "mtnopt: Usage: mtnopt [-c] [-s] [-d dir] [-k keys] [-v]" + echo "mtnopt: Usage: mtnopt [-c] [-s] [-d dir] [-k keys] [-v] [-h]" } while [ ! $# = 0 ]; do case $1 in @@ -38,15 +38,19 @@ while [ ! $# = 0 ]; do -v) values_only=/bin/true ;; + -h) + usage + exit 2 + ;; esac shift done if [ ! -d "$mtn_dir" ]; then - echo "mtnopt: $mtnopt isn't a directory or is missing" + echo "mtnopt: $mtn_dir isn't a directory or is missing" exit 1 elif [ ! -f "$mtn_dir/options" ]; then - echo "mtnopt: $mtnopt isn't a file or is missing" + echo "mtnopt: $mtn_dir/options isn't a file or is missing" exit 1 fi