Comments
Patch
@@ -396,16 +396,13 @@ buildhistory_commit() {
if [ ! -d .git ] ; then
git init -q
fi
- # Ensure there are new/changed files to commit
- repostatus=`git status --porcelain`
- if [ "$repostatus" != "" ] ; then
- git add ${BUILDHISTORY_DIR}/*
- HOSTNAME=`hostname 2>/dev/null || echo unknown`
- git commit ${BUILDHISTORY_DIR}/ -m "Build ${BUILDNAME} of ${DISTRO} ${DISTRO_VERSION} for machine ${MACHINE} on $HOSTNAME" --author "${BUILDHISTORY_COMMIT_AUTHOR}" > /dev/null
- if [ "${BUILDHISTORY_PUSH_REPO}" != "" ] ; then
- git push -q ${BUILDHISTORY_PUSH_REPO}
- fi
- fi) || true
+ git add ${BUILDHISTORY_DIR}/*
+ HOSTNAME=`hostname 2>/dev/null || echo unknown`
+ git commit ${BUILDHISTORY_DIR}/ --allow-empty -m "Build ${BUILDNAME} of ${DISTRO} ${DISTRO_VERSION} for machine ${MACHINE} on $HOSTNAME" --author "${BUILDHISTORY_COMMIT_AUTHOR}" > /dev/null
+ if [ "${BUILDHISTORY_PUSH_REPO}" != "" ] ; then
+ git push -q ${BUILDHISTORY_PUSH_REPO}
+ fi
+ ) || true
}
python buildhistory_eventhandler() {
Allow empty commits, this also give a nice speedup since 'git status --porcelain' doesn't need to get run. Signed-off-by: Koen Kooi <koen@dominion.thruhere.net> --- meta/classes/buildhistory.bbclass | 17 +++++++---------- 1 files changed, 7 insertions(+), 10 deletions(-)