classes/buildhistory: tag last 3 build revisions

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).

(From OE-Core rev: 9512f3787295d662678c2943da31197c8df39e99)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Paul Eggleton 2013-08-15 18:04:37 +01:00 committed by Richard Purdie
parent 742266d660
commit 1e8e24358a
1 changed files with 4 additions and 0 deletions

View 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$"`