[PATCH 9/10] Misc cleanups. Signed-off-by: Jonas Fonseca --- cg-log | 10 +++++----- 1 files changed, 5 insertions(+), 5 deletions(-) diff --git a/cg-log b/cg-log --- a/cg-log +++ b/cg-log @@ -164,6 +164,10 @@ fi print_commit_log() { commit="$1" + author= + committer= + tree= + parents=() git-cat-file commit $commit | \ while read key rest; do @@ -227,14 +231,10 @@ print_commit_log() { $revls | $revsort | while read time commit parents; do trap exit SIGPIPE - author= - committer= - tree= - parents=() [ "$revfmt" = "git-rev-list" ] && commit="$time" log="$(print_commit_log $commit)" if [ "$log" ]; then - echo "$log" + echo "$log" echo fi done | LESS="R$LESS" ${PAGER:-less} ${PAGER_FLAGS}