Skip to content

Commit

Permalink
fix typo in kubectl plugin, and add -h flag for help
Browse files Browse the repository at this point in the history
  • Loading branch information
garethr committed May 18, 2019
1 parent 904c3a2 commit 4a139cb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions plugin/kubectl-conftest.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ function usage () {
echo "See https://github.com/instrumenta/conftest for more information"
echo
echo "Usage:"
echo " kubectl test (TYPE[.VERSION][.GROUP] [NAME] | TYPE[.VERSION][.GROUP]/NAME)"
echo " kubectl conftest (TYPE[.VERSION][.GROUP] [NAME] | TYPE[.VERSION][.GROUP]/NAME)"
}

SCRIPT_DIR="$( cd "$( dirname "$(readlink -f "$0")")" && pwd )"
Expand All @@ -29,7 +29,7 @@ conftest="${SCRIPT_DIR}/conftest"
check_command "kubectl"


if [[ ($# -eq 0) || ($1 == "--help") ]]; then
if [[ ($# -eq 0) || ($1 == "--help") || ($1 == "-h") ]]; then
# No commands or the --help flag passed and we'll show the usage instructions
usage
elif [[ ($# -eq 1) && $1 =~ ^[a-z\.]+$ ]]; then
Expand Down

0 comments on commit 4a139cb

Please sign in to comment.