From 27b94f650cd4d27bbf8bd9fc33030077a675d4d7 Mon Sep 17 00:00:00 2001 From: Simon Ruderich Date: Wed, 18 Feb 2009 21:01:03 +0100 Subject: [PATCH] Only print status output if git log did in sync.sh. --- sync.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/sync.sh b/sync.sh index 7ffcd44..498a2b3 100755 --- a/sync.sh +++ b/sync.sh @@ -28,8 +28,11 @@ for project in `find . -name .git -type d`; do # Display all commits not in the master branch. if [ $method = status ]; then - echo "$project status" - git log --graph --all --pretty=oneline master.. + output=`git log --graph --all --pretty=oneline --color master..` + if [ "x$output" != x ]; then + echo "$project status:" + echo "$output" + fi # Fetch from/Push to all remotes. else for remote in `git remote`; do -- 2.44.1