Skip to content

Commit

Permalink
fix(lib.sh): correct requested_help regex to not match partial words
Browse files Browse the repository at this point in the history
  • Loading branch information
tcodes0 committed Sep 15, 2024
1 parent 00ce548 commit 045f71d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib.sh
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ fatal() {
# Args : $@
# Example : if requested_help "$*"; then echo "help"; fi
requested_help() {
[[ "$*" =~ -h|--help|help ]]
[[ "$*" =~ [[:blank:]]+-h[[:blank:]]+|[[:blank:]]+--help[[:blank:]]+|[[:blank:]]+help[[:blank:]]+ ]]
}

####################
Expand Down

0 comments on commit 045f71d

Please sign in to comment.