Skip to content

Commit

Permalink
Check command is passed
Browse files Browse the repository at this point in the history
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
  • Loading branch information
efrecon and coderabbitai[bot] authored Sep 27, 2024
1 parent 0fa9ec6 commit 31f2b8b
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/common.sh
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,9 @@ check_command() {
esac
done
shift $((OPTIND-1))
if [ -z "$1" ]; then
error "No command specified for checking"
fi
trace "Checking $1 is an accessible command"
if ! command -v "$1" >/dev/null 2>&1; then
if is_true "$_hard"; then
Expand Down

0 comments on commit 31f2b8b

Please sign in to comment.