From 323bb36f7c3af1f56f219b6eb67c183e4a2aa957 Mon Sep 17 00:00:00 2001 From: Jonathan Nieder Date: Wed, 17 Aug 2011 09:09:51 -0500 Subject: [PATCH] changelog.upstream.sh: use rev-list | diff-tree instead of git log MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit The developer’s Git installation might be set up to use --decorate by default or to automatically abbreviate commit names. Use plumbing commands whose output does not depend on configuration to avoid gratuitous differences between the changelogs produced on different machines. Reported-by: Thorsten Glaser --- debian/changelog | 3 +++ debian/changelog.upstream.sh | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index 3dd5ca1a..1db17fb7 100644 --- a/debian/changelog +++ b/debian/changelog @@ -24,6 +24,9 @@ xz-utils (5.1.1alpha+20120510-0.1) unstable; urgency=low flags, including hardening options. Build-Depends: dpkg-dev (>= 1.16.1~). Closes: #653739. * debian/rules: Simplify build-arch rule. + * debian/changelog.upstream.sh: Use ‘git rev-list | git diff-tree’ + instead of ‘git log’ for reliable output independent of the + operator’s configuration. -- Jonathan Nieder Thu, 17 May 2012 19:16:19 -0500 diff --git a/debian/changelog.upstream.sh b/debian/changelog.upstream.sh index fe5d5ea8..afaec0fc 100644 --- a/debian/changelog.upstream.sh +++ b/debian/changelog.upstream.sh @@ -102,7 +102,8 @@ add_version() { limiter="$new_cid.." fi echo - git log --date=iso --stat --no-merges --format=medium "$limiter$last_cid" + git rev-list --no-merges "$limiter$last_cid" | + git diff-tree --date=iso --stat --format=medium --stdin test "$new" = none || echo last=$new -- 2.11.4.GIT