From 8f350340f952029a7f9471a556ed902de8a9ede4 Mon Sep 17 00:00:00 2001 From: Thomas Forgione Date: Thu, 17 Jan 2019 13:57:34 +0100 Subject: [PATCH] Fixed cdgclone --- zsh/gclone.zsh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/zsh/gclone.zsh b/zsh/gclone.zsh index 097eb2f..cc0d7c6 100644 --- a/zsh/gclone.zsh +++ b/zsh/gclone.zsh @@ -46,11 +46,15 @@ if [ -d "$GCLONE_PATH" ]; then cat $GCLONE_PATH/.cdgcache | sort | uniq > $GCLONE_PATH/.cdgcache.tmp mv $GCLONE_PATH/.cdgcache.tmp $GCLONE_PATH/.cdgcache fi + retval=0 + else + retval=1 fi # Remove the temp dir rm -rf $tempdir + return $retval } cdg() { @@ -95,7 +99,7 @@ if [ -d "$GCLONE_PATH" ]; then } cdgclone() { - gclone $1 && cdg $1 + gclone $1 && cdg `basename $1` } _cdg() {