From: Otavio Salvador Date: Thu, 11 Oct 2012 21:46:41 +0000 (+0000) Subject: buildhistory.bbclass: Fix hostname print for 'No changes' case X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=9fe0f62411898d7ad07a77a9207dc156687864c3;p=thirdparty%2Fopenembedded%2Fopenembedded-core-contrib.git buildhistory.bbclass: Fix hostname print for 'No changes' case (From OE-Core rev: f9e3745d8eeef0df7e6dba3ba17d0b00645c92fa) Signed-off-by: Otavio Salvador Signed-off-by: Saul Wold Signed-off-by: Richard Purdie --- diff --git a/meta/classes/buildhistory.bbclass b/meta/classes/buildhistory.bbclass index 49f2ea5b7c1..0a5753f7dcb 100644 --- a/meta/classes/buildhistory.bbclass +++ b/meta/classes/buildhistory.bbclass @@ -403,9 +403,9 @@ END fi # Check if there are new/changed files to commit (other than metadata-revs) repostatus=`git status --porcelain | grep -v " metadata-revs$"` + HOSTNAME=`hostname 2>/dev/null || echo unknown` if [ "$repostatus" != "" ] ; then git add . - HOSTNAME=`hostname 2>/dev/null || echo unknown` # porcelain output looks like "?? packages/foo/bar" # Ensure we commit metadata-revs with the first commit for entry in `echo "$repostatus" | awk '{print $2}' | awk -F/ '{print $1}' | sort | uniq` ; do