mirror of
https://github.com/kdabir/has.git
synced 2024-11-11 14:40:48 +01:00
Fix for #22 - let has eat it's own dogfood
This commit is contained in:
parent
f6fe16c659
commit
3136085c75
1 changed files with 6 additions and 1 deletions
7
has
7
has
|
@ -116,6 +116,11 @@ __detect(){
|
|||
status=$?
|
||||
;;
|
||||
|
||||
has)
|
||||
version=$(has 2>&1 | egrep -o "$REGEX_SIMPLE_VERSION" | head -1)
|
||||
status=$?
|
||||
;;
|
||||
|
||||
*)
|
||||
## Can allow dynamic checking here, i.e. checking commands that are not listed above
|
||||
if [[ "${HAS_ALLOW_UNSAFE}" == "y" ]]; then
|
||||
|
@ -158,7 +163,7 @@ __detect(){
|
|||
if [ "$#" -eq 0 ]; then
|
||||
# print help
|
||||
BINARY_NAME="has"
|
||||
VERSION="v1.1.0"
|
||||
VERSION="v1.2.0"
|
||||
echo "${BINARY_NAME} ${VERSION}"
|
||||
echo "USAGE: ${BINARY_NAME} <command-names>.."
|
||||
echo "EXAMPLE: ${BINARY_NAME} git curl node"
|
||||
|
|
Loading…
Reference in a new issue