diff options
author | Markus Lehtonen <markus.lehtonen@linux.intel.com> | 2016-01-27 14:50:53 +0200 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-01-29 18:14:53 +0000 |
commit | a5e931e0b1d941cc938fe2f49625c54b07fab0ce (patch) | |
tree | b50a82fc04d8faa8c8082973ba7595769dae399f /meta/classes/buildhistory.bbclass | |
parent | 20c897d34ba4ea3985723383a0effa3631cd925e (diff) | |
download | openembedded-core-a5e931e0b1d941cc938fe2f49625c54b07fab0ce.tar.gz openembedded-core-a5e931e0b1d941cc938fe2f49625c54b07fab0ce.tar.bz2 openembedded-core-a5e931e0b1d941cc938fe2f49625c54b07fab0ce.zip |
buildhistory: fix the check for existence of a git repo
Previously, in order to determine the existence of an already
initialized Git repository we checked if a directory named '.git' was
present in the buildhistory dir. However, e.g. in the case of git
submodules '.git' may also be a regular file referencing some other
location which was causing unwanted behavior. This patch changes
buildhistory.bbclass to check for any file named '.git' which fixes
these problems.
[YOCTO #8911]
Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Diffstat (limited to 'meta/classes/buildhistory.bbclass')
-rw-r--r-- | meta/classes/buildhistory.bbclass | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/meta/classes/buildhistory.bbclass b/meta/classes/buildhistory.bbclass index 9f1744293a..3c4647ac7b 100644 --- a/meta/classes/buildhistory.bbclass +++ b/meta/classes/buildhistory.bbclass @@ -684,7 +684,7 @@ END ( cd ${BUILDHISTORY_DIR}/ # Initialise the repo if necessary - if [ ! -d .git ] ; then + if [ ! -e .git ] ; then git init -q else git tag -f build-minus-3 build-minus-2 > /dev/null 2>&1 || true |