From dc0cd5c4d198d2090d14f09c0ef05518194bd83a Mon Sep 17 00:00:00 2001 From: Ding-Yi Chen Date: Aug 19 2016 04:34:56 +0000 Subject: cmake-fedora-fedpkg: fix when git change is at staging, but not committed yet --- diff --git a/ChangeLog b/ChangeLog index 7fa5183..495008c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +* Fri Aug 19 2016 Ding-Yi Chen - 2.7.1 +- Bugs: + + cmake-fedora-fedpkg: fix when git change is at staging, but not committed yet. + * Wed Aug 17 2016 Ding-Yi Chen - 2.7.0 - Enhancement: + cmake-fedora-reset: The program that clean and reset the build environment diff --git a/RELEASE-NOTES.txt b/RELEASE-NOTES.txt index 6a7e66b..7cff585 100644 --- a/RELEASE-NOTES.txt +++ b/RELEASE-NOTES.txt @@ -1,9 +1,7 @@ -PRJ_VER=2.7.0 -SUMMARY=Fix cmake-fedora-fedpkg: failed when commit is clean +PRJ_VER=2.7.1 +SUMMARY=cmake-fedora-fedpkg: fix when git change is at staging, but not committed yet REDHAT_BUGZILLA=1367656 [Changes] -- Enhancement: - + cmake-fedora-reset: The program that clean and reset the build environment - Bugs: - + Fixed Bug 1367656 - cmake-fedora-fedpkg: failed when commit is clean + + cmake-fedora-fedpkg: fix when git change is at staging, but not committed yet. diff --git a/scripts/cmake-fedora-fedpkg b/scripts/cmake-fedora-fedpkg index 0f201fe..08aa94a 100755 --- a/scripts/cmake-fedora-fedpkg +++ b/scripts/cmake-fedora-fedpkg @@ -185,7 +185,8 @@ function fedpkg_build(){ try_command $FEDPKG_CMD switch-branch $gitBranch try_command $FEDPKG_CMD pull try_command $FEDPKG_CMD import "$Srpm" - if ! $GIT_CMD diff --exit-code ;then + ## git diff --quiet also imply --exit-code + if ! $GIT_CMD diff --quiet HEAD ;then # Has something to commit try_command $FEDPKG_CMD commit -m "$ChangeLogText" fi