chiark / gitweb /
fix stg mail %(shortlog)s order
authorAlex Chiang <achiang@hp.com>
Fri, 10 Jul 2009 09:32:06 +0000 (10:32 +0100)
committerCatalin Marinas <catalin.marinas@arm.com>
Fri, 10 Jul 2009 09:32:06 +0000 (10:32 +0100)
When using the %(shortlog)s variable, the patches are listed in
the cover letter in the reverse order of the actual patch series.

We should list them in the actual order of the patch series instead.

Signed-off-by: Alex Chiang <achiang@hp.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
stgit/commands/mail.py

index 69b19fa8952aec35328f420b02228bc7c52ac9df..abd42e481b69a2c4d5289479d4bc84a517b6affa 100644 (file)
@@ -399,7 +399,7 @@ def __build_cover(tmpl, patches, msg_id, options):
                  'totalnr':      total_nr_str,
                  'number':       number_str,
                  'shortlog':     stack.shortlog(crt_series.get_patch(p)
-                                                for p in patches),
+                                                for p in reversed(patches)),
                  'diffstat':     gitlib.diffstat(git.diff(
                      rev1 = git_id(crt_series, '%s^' % patches[0]),
                      rev2 = git_id(crt_series, '%s' % patches[-1]),