Skip to content

Commit

Permalink
Revert to the old behaviour where, when used with no parameters, usag…
Browse files Browse the repository at this point in the history
…e is shown.
  • Loading branch information
lhernanz committed Dec 29, 2017
1 parent 1aaa5e8 commit 19552a2
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions Linux/flash
Original file line number Diff line number Diff line change
Expand Up @@ -107,15 +107,19 @@ beginswith() { case $2 in $1*) true;; *) false;; esac; }
endswith() { case $2 in *$1) true;; *) false;; esac; }

if [ $# -lt 1 ]; then
CONFIGURE_ONLY=1
echo "Configuration mode. No image will be written"
usage
fi

if [[ "$1" == "--help" ]]; then
usage
fi
image=$1

if [[ -z $image ]]; then
CONFIGURE_ONLY=1
echo "Configuration mode. No image will be written"
fi

filename=$(basename "${image}")
extension="${filename##*.}"
filename="${filename%.*}"
Expand Down

0 comments on commit 19552a2

Please sign in to comment.