git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] format-patch: clarify --creation-factor=<factor>

From
Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Date
Jul 28, 2022, 20:55 UTC
Message-ID
<220728.867d3xj6s0.gmgdl@evledraar.gmail.com>
In-Reply-To
<20220728174953.66964-1-sunshine@sunshineco.com>
On Thu, Jul 28 2022, Eric Sunshine wrote:
Show 36 quoted lines
> The value is not a percentage that ranges from 0 to 100, so stop
> referring to it as `percent`; instead follow the lead of the `git
> range-diff` documentation and call it `factor`.
>
> Signed-off-by: Eric Sunshine <sunshine@sunshineco.com>
> ---
>
> This is a sibling to Junio's patch[1].
>
> [1]: https://lore.kernel.org/git/xmqqo7x9ch7n.fsf_-_@gitster.g/
>
>  Documentation/git-format-patch.txt | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/Documentation/git-format-patch.txt b/Documentation/git-format-patch.txt
> index be797d7a28..e06475abcd 100644
> --- a/Documentation/git-format-patch.txt
> +++ b/Documentation/git-format-patch.txt
> @@ -27,7 +27,7 @@ SYNOPSIS
>  		   [--[no-]encode-email-headers]
>  		   [--no-notes | --notes[=<ref>]]
>  		   [--interdiff=<previous>]
> -		   [--range-diff=<previous> [--creation-factor=<percent>]]
> +		   [--range-diff=<previous> [--creation-factor=<factor>]]
>  		   [--filename-max-length=<n>]
>  		   [--progress]
>  		   [<common diff options>]
> @@ -321,7 +321,7 @@ product of `format-patch` is generated, and they are not passed to
>  the underlying `range-diff` machinery used to generate the cover-letter
>  material (this may change in the future).
>  
> ---creation-factor=<percent>::
> +--creation-factor=<factor>::
>  	Used with `--range-diff`, tweak the heuristic which matches up commits
>  	between the previous and current series of patches by adjusting the
>  	creation/deletion cost fudge factor. See linkgit:git-range-diff[1])

Looks good as far as it goes, looks like both of your patches need to also tweak this bit though:

	$ git -P grep 'percentage.*creation' -- '*.c'
	builtin/log.c:                      N_("percentage by which creation is weighted")),
	builtin/range-diff.c:                       N_("percentage by which creation is weighted")),
Probably just s/percentage/factor/ in for those -h strings?
Previous: Eric SunshineNext: Junio C Hamano
Message 9 of 17 in “--creation-factor=100 does not show code”
  1. Eugen KonkovJul 26, 2022
  2. Johannes SchindelinJul 28, 2022
  3. Re* --creation-factor=100 does not show codeJunio C Hamano, Jul 28, 2022
  4. Ævar Arnfjörð BjarmasonJul 28, 2022
  5. Junio C HamanoJul 28, 2022
  6. Ævar Arnfjörð BjarmasonJul 28, 2022
  7. Junio C HamanoJul 28, 2022
  8. format-patch: clarify --creation-factor=<factor>Eric Sunshine, Jul 28, 2022
  9. Ævar Arnfjörð BjarmasonJul 28, 2022
  10. Junio C HamanoJul 28, 2022
  11. Eric SunshineJul 28, 2022
  12. Eric SunshineJul 30, 2022
  13. Junio C HamanoJul 31, 2022
  14. Johannes SchindelinJul 29, 2022
  15. Junio C HamanoJul 29, 2022
  16. Junio C HamanoAug 1, 2022
  17. Eugen KonkovApr 2, 2023

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.