Improve collection of information for format-patch --cover-letter

Use the "boundary" feature to find the origin (or find that there are
multiple origins), and use the actual list of commits to pass to
shortlog.

This makes all cover letter include shortlogs, and all cover letters
for series with a single boundary commit include diffstats (if there
are multiple boundary commits it's unclear what would be meaningful as
a diffstat). Note that the single boundary test is empirical, not
theoretical; even a -2 limiting condition will give a diffstat if there's
only one boundary commit in this particular case.

Signed-off-by: Daniel Barkalow <barkalow@iabervon.org>
1 file changed
tree: 073e68688324f875786d27c3e873648c5a59a484
  1. arm/
  2. compat/
  3. contrib/
  4. Documentation/
  5. git-gui/
  6. gitk-git/
  7. gitweb/
  8. mozilla-sha1/
  9. perl/
  10. ppc/
  11. t/
  12. templates/
  13. xdiff/
  14. .gitattributes
  15. .gitignore
  16. .mailmap
  17. alloc.c
  18. archive-tar.c
  19. archive-zip.c
  20. archive.c
  21. archive.h
  22. attr.c
  23. attr.h
  24. base85.c
  25. blob.c
  26. blob.h
  27. builtin-add.c
  28. builtin-annotate.c
  29. builtin-apply.c
  30. builtin-archive.c
  31. builtin-blame.c
  32. builtin-branch.c
  33. builtin-bundle.c
  34. builtin-cat-file.c
  35. builtin-check-attr.c
  36. builtin-check-ref-format.c
  37. builtin-checkout-index.c
  38. builtin-clean.c
  39. builtin-commit-tree.c
  40. builtin-commit.c
  41. builtin-config.c
  42. builtin-count-objects.c
  43. builtin-describe.c
  44. builtin-diff-files.c
  45. builtin-diff-index.c
  46. builtin-diff-tree.c
  47. builtin-diff.c
  48. builtin-fast-export.c
  49. builtin-fetch--tool.c
  50. builtin-fetch-pack.c
  51. builtin-fetch.c
  52. builtin-fmt-merge-msg.c
  53. builtin-for-each-ref.c
  54. builtin-fsck.c
  55. builtin-gc.c
  56. builtin-grep.c
  57. builtin-http-fetch.c
  58. builtin-init-db.c
  59. builtin-log.c
  60. builtin-ls-files.c
  61. builtin-ls-remote.c
  62. builtin-ls-tree.c
  63. builtin-mailinfo.c
  64. builtin-mailsplit.c
  65. builtin-merge-base.c
  66. builtin-merge-file.c
  67. builtin-merge-ours.c
  68. builtin-mv.c
  69. builtin-name-rev.c
  70. builtin-pack-objects.c
  71. builtin-pack-refs.c
  72. builtin-prune-packed.c
  73. builtin-prune.c
  74. builtin-push.c
  75. builtin-read-tree.c
  76. builtin-reflog.c
  77. builtin-rerere.c
  78. builtin-reset.c
  79. builtin-rev-list.c
  80. builtin-rev-parse.c
  81. builtin-revert.c
  82. builtin-rm.c
  83. builtin-send-pack.c
  84. builtin-shortlog.c
  85. builtin-show-branch.c
  86. builtin-show-ref.c
  87. builtin-stripspace.c
  88. builtin-symbolic-ref.c
  89. builtin-tag.c
  90. builtin-tar-tree.c
  91. builtin-unpack-objects.c
  92. builtin-update-index.c
  93. builtin-update-ref.c
  94. builtin-upload-archive.c
  95. builtin-verify-pack.c
  96. builtin-verify-tag.c
  97. builtin-write-tree.c
  98. builtin.h
  99. bundle.c
  100. bundle.h
  101. cache-tree.c
  102. cache-tree.h
  103. cache.h
  104. check-builtins.sh
  105. check-racy.c
  106. color.c
  107. color.h
  108. combine-diff.c
  109. command-list.txt
  110. commit.c
  111. commit.h
  112. config.c
  113. config.mak.in
  114. configure.ac
  115. connect.c
  116. convert.c
  117. copy.c
  118. COPYING
  119. csum-file.c
  120. csum-file.h
  121. ctype.c
  122. daemon.c
  123. date.c
  124. decorate.c
  125. decorate.h
  126. delta.h
  127. diff-delta.c
  128. diff-lib.c
  129. diff.c
  130. diff.h
  131. diffcore-break.c
  132. diffcore-delta.c
  133. diffcore-order.c
  134. diffcore-pickaxe.c
  135. diffcore-rename.c
  136. diffcore.h
  137. dir.c
  138. dir.h
  139. dump-cache-tree.c
  140. entry.c
  141. environment.c
  142. exec_cmd.c
  143. exec_cmd.h
  144. fast-import.c
  145. fetch-pack.h
  146. fixup-builtins
  147. generate-cmdlist.sh
  148. git-add--interactive.perl
  149. git-am.sh
  150. git-archimport.perl
  151. git-bisect.sh
  152. git-checkout.sh
  153. git-clone.sh
  154. git-compat-util.h
  155. git-cvsexportcommit.perl
  156. git-cvsimport.perl
  157. git-cvsserver.perl
  158. git-filter-branch.sh
  159. git-instaweb.sh
  160. git-lost-found.sh
  161. git-merge-octopus.sh
  162. git-merge-one-file.sh
  163. git-merge-resolve.sh
  164. git-merge-stupid.sh
  165. git-merge.sh
  166. git-mergetool.sh
  167. git-parse-remote.sh
  168. git-pull.sh
  169. git-quiltimport.sh
  170. git-rebase--interactive.sh
  171. git-rebase.sh
  172. git-relink.perl
  173. git-remote.perl
  174. git-repack.sh
  175. git-request-pull.sh
  176. git-send-email.perl
  177. git-sh-setup.sh
  178. git-stash.sh
  179. git-submodule.sh
  180. git-svn.perl
  181. GIT-VERSION-GEN
  182. git-web--browse.sh
  183. git.c
  184. git.spec.in
  185. grep.c
  186. grep.h
  187. hash-object.c
  188. hash.c
  189. hash.h
  190. help.c
  191. http-push.c
  192. http-walker.c
  193. http.c
  194. http.h
  195. ident.c
  196. imap-send.c
  197. index-pack.c
  198. INSTALL
  199. interpolate.c
  200. interpolate.h
  201. list-objects.c
  202. list-objects.h
  203. lockfile.c
  204. log-tree.c
  205. log-tree.h
  206. mailmap.c
  207. mailmap.h
  208. Makefile
  209. match-trees.c
  210. merge-file.c
  211. merge-index.c
  212. merge-recursive.c
  213. merge-tree.c
  214. mktag.c
  215. mktree.c
  216. object-refs.c
  217. object.c
  218. object.h
  219. pack-check.c
  220. pack-redundant.c
  221. pack-write.c
  222. pack.h
  223. pager.c
  224. parse-options.c
  225. parse-options.h
  226. patch-delta.c
  227. patch-id.c
  228. patch-ids.c
  229. patch-ids.h
  230. path-list.c
  231. path-list.h
  232. path.c
  233. pkt-line.c
  234. pkt-line.h
  235. pretty.c
  236. progress.c
  237. progress.h
  238. quote.c
  239. quote.h
  240. reachable.c
  241. reachable.h
  242. read-cache.c
  243. README
  244. receive-pack.c
  245. reflog-walk.c
  246. reflog-walk.h
  247. refs.c
  248. refs.h
  249. remote.c
  250. remote.h
  251. revision.c
  252. revision.h
  253. run-command.c
  254. run-command.h
  255. send-pack.h
  256. server-info.c
  257. setup.c
  258. sha1_file.c
  259. sha1_name.c
  260. shallow.c
  261. shell.c
  262. shortlog.h
  263. show-index.c
  264. sideband.c
  265. sideband.h
  266. strbuf.c
  267. strbuf.h
  268. symlinks.c
  269. tag.c
  270. tag.h
  271. tar.h
  272. test-absolute-path.c
  273. test-chmtime.c
  274. test-date.c
  275. test-delta.c
  276. test-genrandom.c
  277. test-match-trees.c
  278. test-parse-options.c
  279. test-sha1.c
  280. test-sha1.sh
  281. trace.c
  282. transport.c
  283. transport.h
  284. tree-diff.c
  285. tree-walk.c
  286. tree-walk.h
  287. tree.c
  288. tree.h
  289. unpack-file.c
  290. unpack-trees.c
  291. unpack-trees.h
  292. update-server-info.c
  293. upload-pack.c
  294. usage.c
  295. utf8.c
  296. utf8.h
  297. var.c
  298. walker.c
  299. walker.h
  300. write_or_die.c
  301. ws.c
  302. wt-status.c
  303. wt-status.h
  304. xdiff-interface.c
  305. xdiff-interface.h