From a2cd862d532aeb888aebacfa94ce41f59e5226f7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Zurcher?= Date: Tue, 3 Jan 2012 23:43:17 +0100 Subject: deploy-ruby-tasks: add help function --- deploy-ruby-tasks | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/deploy-ruby-tasks b/deploy-ruby-tasks index f3fae27..37d1186 100755 --- a/deploy-ruby-tasks +++ b/deploy-ruby-tasks @@ -1,5 +1,14 @@ #! /bin/sh +function help() { + echo "${0##*/} [dtcu] " + echo -e "\t-d --git-dir set GIT_DIR" + echo -e "\t-t --tasks-dir set TASKS_DIR" + echo -e "\t-c --no-create set NO_CREATE" + echo -e "\t-u --force-update set FORCE_UPDATE" + exit 0 +} + for arg in $@; do option=`echo "'$arg'" | cut -d'=' -f1 | tr -d "'"` value=`echo "'$arg'" | cut -d'=' -f2- | tr -d "'"` @@ -9,7 +18,7 @@ for arg in $@; do -t|--tasks-dir) TASKS_DIR=$value;; -c|--no-create) NO_CREATE=1;; -u|--force-update) FORCE_UPDATE=1;; - *) GIT_REMOTE=$arg;; + -h|--help) help;; esac done -- cgit v1.1-2-g2b99