]> code.ossystems Code Review - openembedded-core.git/commitdiff
classes/buildhistory: tag last 3 build revisions
authorPaul Eggleton <paul.eggleton@linux.intel.com>
Thu, 15 Aug 2013 17:04:37 +0000 (18:04 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 16 Aug 2013 10:37:52 +0000 (11:37 +0100)
This makes it easier to obtain the difference from the last three
builds particularly where a single build might account for more than one
commit in the buildhistory git repository (e.g. if package and image
changes occurred).

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/buildhistory.bbclass

index 6fb1ba646dbc6608f3633dcfb46b67dcdf1299da..e3f92018f22750b19af65d8cd683af09e8afb8ae 100644 (file)
@@ -518,6 +518,10 @@ END
                # Initialise the repo if necessary
                if [ ! -d .git ] ; then
                        git init -q
+               else
+                       git tag -f build-minus-3 build-minus-2 > /dev/null 2>&1 || true
+                       git tag -f build-minus-2 build-minus-1 > /dev/null 2>&1 || true
+                       git tag -f build-minus-1 > /dev/null 2>&1 || true
                fi
                # Check if there are new/changed files to commit (other than metadata-revs)
                repostatus=`git status --porcelain | grep -v " metadata-revs$"`