From 1873a4c0d0683591269502def35948ead3c99b5d Mon Sep 17 00:00:00 2001 From: Teddy Wing Date: Wed, 18 Apr 2018 23:08:51 +0200 Subject: Add a usage function --- redprine | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/redprine b/redprine index 32a1445..88c4fe5 100755 --- a/redprine +++ b/redprine @@ -13,6 +13,21 @@ REDMINE_TOKEN='' CACHE_FILE="$HOME/redprine.json" + +function print_usage () { + cat 1>&2 <<__EOF__ +Usage: redprine --github-token TOKEN --github-username USERNAME --redmine-base-url URL --redmine-token TOKEN + +Flags: + --github-token=TOKEN GitHub API token with pull request access. + --github-username=USERNAME GitHub username. + --redmine-base-url=URL Base Redmine URL (e.g. 'https://redmine.eaglejump.co') + --redmine-token=TOKEN Redmine account API key + -h, --help Show this help. + -v, --version Show application version. +__EOF__ +} + function github_owner_repo () { local git_remote=$(git remote get-url origin) local owner_repo=$(echo "$git_remote" | -- cgit v1.2.3