From 442fdac531a6b042a396eafc096811e46bc063ca Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Tue, 31 Oct 2023 17:38:44 +0100 Subject: check if git dir before doing anything --- bin/extra/supd | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'bin') diff --git a/bin/extra/supd b/bin/extra/supd index e8eacd4..61ea144 100755 --- a/bin/extra/supd +++ b/bin/extra/supd @@ -17,9 +17,10 @@ fi for dir in $dirs do - printf '%s:' "$dir" | >&2 sed "s#$HOME#~#" ( cd "$dir" || return + git rev-parse > /dev/null 2>&1 || return + printf '%s:' "$dir" | >&2 sed "s#$HOME#~#" git "${1:-fetch}" > /dev/null 2>&1 && printf ' o' || printf ' x' -- cgit v1.2.3