aboutsummaryrefslogtreecommitdiffhomepage
path: root/git-dch
diff options
context:
space:
mode:
authorGuido Guenther <agx@sigxcpu.org>2007-12-15 14:35:44 +0100
committerGuido Guenther <agx@sigxcpu.org>2007-12-15 14:35:44 +0100
commita104bb14126f3cdc04f66615304470ea3546eeb5 (patch)
treedcb396518b17ed298a0d638044eb86d714d51986 /git-dch
parent116048b7b7c05f4a461a2da402ac73bf04ce589f (diff)
don't start a new changelog section if we found a snapshot header even when distribution != UNRELEASED
Diffstat (limited to 'git-dch')
-rwxr-xr-xgit-dch4
1 files changed, 3 insertions, 1 deletions
diff --git a/git-dch b/git-dch
index b98ce378..cb0e015b 100755
--- a/git-dch
+++ b/git-dch
@@ -187,6 +187,7 @@ def main(argv):
ret = 0
changelog = 'debian/changelog'
until = 'HEAD'
+ found_snapshot_header = False
parser = GbpOptionParser(command=os.path.basename(argv[0]), prefix='',
usage='%prog [options] paths')
@@ -237,6 +238,7 @@ def main(argv):
since = guess_snapshot_commit(cp)
if since:
print "Continuing from commit '%s'" % since
+ found_snapshot_header = True
else:
print "Couldn't get snapshot header, using version info"
if not since:
@@ -246,7 +248,7 @@ def main(argv):
print "Only looking for changes on '%s'" % " ".join(args)
changes = get_log(since, until, options.git_log, " ".join(args))
if changes:
- if cp['Distribution'] != "UNRELEASED":
+ if cp['Distribution'] != "UNRELEASED" and not found_snapshot_header:
add_changelog_section(distribution="UNRELEASED", msg="UNRELEASED")
shortlog_to_dch(changes)
fixup_trailer()