From 102278182159d51c1417716536358540010a0f8e Mon Sep 17 00:00:00 2001 From: Lukas Fleischer Date: Fri, 1 Jun 2012 14:18:05 +0200 Subject: calcurse-upgrade: Add "-h" and "-v" options Add "-h"/"--help" options to print a usage message and "-v"/"--version" to print the current version. Signed-off-by: Lukas Fleischer --- scripts/calcurse-upgrade.sh.in | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'scripts') diff --git a/scripts/calcurse-upgrade.sh.in b/scripts/calcurse-upgrade.sh.in index bf3f92e..8789604 100644 --- a/scripts/calcurse-upgrade.sh.in +++ b/scripts/calcurse-upgrade.sh.in @@ -9,6 +9,15 @@ CONFFILE=$HOME/.calcurse/conf if [ "$#" -gt 0 ]; then if [ "$1" = "--config" ]; then CONFFILE=$2 + elif [ "$1" = "-h" -o "$1" = "--help" ]; then + echo "calcurse-upgrade @PACKAGE_VERSION@" + echo "$(gettext "Usage: calcurse-upgrade [-h|-v|--config ]")" + elif [ "$1" = "-v" -o "$1" = "--version" ]; then + echo "calcurse-upgrade @PACKAGE_VERSION@" + echo "$(gettext " +Copyright (c) 2004-2012 calcurse Development Team. +This is free software; see the source for copying conditions. +")" else echo "$(gettext "unrecognized option:") \"$1\"" >&2 exit 1 -- cgit v1.2.3-70-g09d2