Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
patch: format-patches with a standard abbrev setting
Prior to this change, each .patch file we wrote would contain abbreviated sha1 values. In Git 2.10 and earlier, these abbreviations were seven characters long. In Git v2.11.0, the core.abbrev default changed to "auto", which means these abbreviation character lengths will scale up and down depending on the size of the Git repository. They could be seven characters, or more. This makes "rdopkg patch" non-idempotent across this version boundary. Git v2.11 can rewrite .patch files to have longer abbreviations than what older Git versions originally constructed. Practically speaking, this divide can happen when running rdopkg on a RHEL 7 environment (with older Git) and then running it on the same repo on Fedora 26 (with newer Git). The end result is that rdopkg can no longer tell which patches really changed, and it incorrectly bumps the release, adds a %changelog, etc. even when nothing changed on a -patches branch. Hard-code the Git core.abbrev setting during the "format-patch" command so that we write the same .patch files in all environments. Change-Id: I4dee29415db21efa49cadacf483eff1fc7b8cc51
- Loading branch information