diff options
| author | Joshua Boniface <joshua@boniface.me> | 2019-01-19 22:02:19 -0500 |
|---|---|---|
| committer | Joshua Boniface <joshua@boniface.me> | 2019-01-19 22:05:41 -0500 |
| commit | bc18d5341c09bb3e5c122b0e447bb134ce62d81e (patch) | |
| tree | 4177b3fd7368cb9f9cc48b1a11a3b2da27650bf6 /build | |
| parent | 99dfb8549f3c2a633e15efc64c51cb8a7b78bd86 (diff) | |
Make help and usage setup standards-compliant
Diffstat (limited to 'build')
| -rwxr-xr-x | build | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -32,7 +32,13 @@ usage() { echo -e "Build output files are collected at '../jellyfin-build/<platform>'." } +# Show usage on stderr with exit 1 on argless if [[ -z $1 ]]; then + usage >&2 + exit 1 +fi +# Show usage if -h or --help are specified in the args +if [[ $@ =~ '-h' || $@ =~ '--help' ]]; then usage exit 0 fi |
