From b0706ff7f3507088c64e8069b5e97f3934ab8cf9 Mon Sep 17 00:00:00 2001 From: Gurkirat Singh Date: Sat, 12 Jun 2021 03:28:40 +0530 Subject: [PATCH] helpers (bugfix): replace length check with -n --- lib/helpers.bash | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/helpers.bash b/lib/helpers.bash index 0f9e51ed..b630947b 100644 --- a/lib/helpers.bash +++ b/lib/helpers.bash @@ -225,7 +225,7 @@ _bash-it-update-() { cd "${BASH_IT}" || return DIFF=$(git diff --name-status) - [ ${#DIFF} -gt 0 ] && echo -e "Either commit your changes using git commit, or clean them...\n$DIFF" && return 1 + [ -n "$DIFF" ] && echo -e "Either commit your changes using git commit, or clean them...\n$DIFF" && return 1 if [ -z "$BASH_IT_REMOTE" ]; then BASH_IT_REMOTE="origin"