Teach "format-patch" to prefix v4- to its output files for the
fourth iteration of a patch series, to make it easier for the
submitter to keep separate copies for iterations.
* jc/format-patch-reroll:
format-patch: give --reroll-count a short synonym -v
format-patch: document and test --reroll-count
format-patch: add --reroll-count=$N option
get_patch_filename(): split into two functions
get_patch_filename(): drop "just-numbers" hack
get_patch_filename(): simplify function signature
builtin/log.c: stop using global patch_suffix
builtin/log.c: drop redundant "numbered_files" parameter from make_cover_letter()
builtin/log.c: drop unused "numbered" parameter from make_cover_letter()
@ -166,6 +166,15 @@ will want to ensure that threading is disabled for `git send-email`.
@@ -166,6 +166,15 @@ will want to ensure that threading is disabled for `git send-email`.
allows for useful naming of a patch series, and can be
combined with the `--numbered` option.
-v <n>::
--reroll-count=<n>::
Mark the series as the <n>-th iteration of the topic. The
output filenames have `v<n>` pretended to them, and the
subject prefix ("PATCH" by default, but configurable via the
`--subject-prefix` option) has ` v<n>` appended to it. E.g.
`--reroll-count=4` may produce `v4-0001-add-makefile.patch`
file that has "Subject: [PATCH v4 1/20] Add makefile" in it.
--to=<email>::
Add a `To:` header to the email headers. This is in addition
to any configured headers, and may be used multiple times.
@ -299,26 +299,34 @@ static unsigned int digits_in_number(unsigned int number)
@@ -299,26 +299,34 @@ static unsigned int digits_in_number(unsigned int number)
return result;
}
void get_patch_filename(struct commit *commit, const char *subject, int nr,