From: Sergey Matveev Date: Wed, 20 Mar 2024 09:59:13 +0000 (+0300) Subject: Do not fail if no comment file exists X-Git-Url: http://www.git.stargrave.org/?a=commitdiff_plain;h=fcadec7fce9d77facc93c0c0b3dfcf18c7de74f3c6f339307af3f9f1716661a7;p=schwabrak.git Do not fail if no comment file exists --- diff --git a/comment-list b/comment-list index c2a673c..1565bb8 100755 --- a/comment-list +++ b/comment-list @@ -6,6 +6,7 @@ root=$0:h:a [[ -n $NO_COLOR ]] || coloured_git=--color issue=${1#issues/} +[[ -e issues/$issue/comment ]] || exit 0 hashes=(`git log --format=format:%H issues/$issue/comment`) for i ({${#hashes}..1}) { comment=`git cat-file blob ${hashes[$i]}:issues/$issue/comment | sed "s/^/+ /"`