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

Re: [RFCv2/FYI] git-sequencer.txt

From
Paolo Bonzini <bonzini@gnu.org>
Date
Jun 12, 2008, 01:31 UTC
Message-ID
<48507C70.8010402@gnu.org>
In-Reply-To
<20080612002258.GC7200@leksak.fem-net>
> 	--collect-signoffs;;
> 		Collect the Signed-by-off: lines of each commit and
> 		add them to the squashed commit message.

I think this makes sense only if -m/-F/-C/-c (see later) is used, because otherwise the default behavior would be to concatenate all messages and call the editor, right? Would it be a no-op if those options are not given?

Show 5 quoted lines
> tag <tag>::
> 	Set tag `<tag>` to the current HEAD,
> 	see also linkgit:git-tag[1].
> 	If another commit is tagged `<tag>`, it will lose this tag,
> 	i.e. the tag will be reset to HEAD.

Is this a lightweight or a heavyweight tag? I guess lightweight -- the tag command should probably support -a, -s and -u like git-tag does. Unless -c/-C/-F/-m is given, the sequencer will then run the editor.

> -C <commit-ish>::
> --reuse-commit=<commit-ish>::
> --reference=<commit-ish>::
> 	Reuse message and authorship data from specified commit.
Why --reference?  Also,
Show 5 quoted lines
> -M <commit-ish>
> --reuse-message=<commit-ish>::
> 	Reuse message from specified commit.
> 	Note, that only the commit message is reused
> 	and not the authorship information.
For consistency with git-commit I would think it's better to have
   -c <commit-ish>::
   -C <commit-ish>::
   --reedit-message=<commit-ish>::
   --reuse-message=<commit-ish>::
	Take existing commit object, and reuse the log message and the
         authorship information (including the timestamp) when creating
         the commit. With -C (or --reuse-message), the editor is not
	invoked; with -c (or --reedit-message) the user can further edit
	the commit message.

(I know it's confusing that it's reusing the message too, but...) and then a separate option:

   -A
   --author-override::
	Force authorship information for commits created by the command
	to be the data in git's configuration files.
... if it is not too complicated to implement.

To satisfy Pierre's comment, you might also add a "-e" general option, which forces an invocation of the editor -- even if -C/-m/-F are given, and even if the command is pick/patch/merge. I guess that in order to support -C/-m/-F you already have to use git-cherry-pick and git-merge's --no-commit options, so it should not be hard to implement.

Paolo
Previous: Stephan BeyerNext: Stephan Beyer
Message 30 of 41 in “[RFC] git-sequencer.txt”
  1. Stephan BeyerJun 7, 2008
  2. squashing patches (was: Re: [RFC] git-sequencer.txt)Stephan Beyer, Jun 9, 2008
  3. Johannes SchindelinJun 9, 2008
  4. Paolo BonziniJun 9, 2008
  5. Paolo BonziniJun 9, 2008
  6. Stephan BeyerJun 9, 2008
  7. Paolo BonziniJun 9, 2008
  8. Add git-squash tool and testsStephan Beyer, Jun 9, 2008
  9. Johannes SchindelinJun 9, 2008
  10. Paolo BonziniJun 9, 2008
  11. Johannes SchindelinJun 9, 2008
  12. Stephan BeyerJun 9, 2008
  13. Johannes SchindelinJun 10, 2008
  14. Stephan BeyerJun 9, 2008
  15. Junio C HamanoJun 9, 2008
  16. Stephan BeyerJun 9, 2008
  17. Jeff KingJun 9, 2008
  18. Stephan BeyerJun 9, 2008
  19. Jeff KingJun 10, 2008
  20. Junio C HamanoJun 9, 2008
  21. Stephan BeyerJun 10, 2008
  22. Jakub NarebskiJun 9, 2008
  23. Stephan BeyerJun 10, 2008
  24. Christian CouderJun 10, 2008
  25. Stephan BeyerJun 10, 2008
  26. Christian CouderJun 11, 2008
  27. Daniel BarkalowJun 11, 2008
  28. Jakub NarebskiJun 10, 2008
  29. [RFCv2/FYI] git-sequencer.txtStephan Beyer, Jun 12, 2008
  30. Paolo BonziniJun 12, 2008
  31. Stephan BeyerJun 12, 2008
  32. git-commit: Change --reuse-message to --reuse-commit.Stephan Beyer, Jun 12, 2008
  33. Paolo BonziniJun 12, 2008
  34. Junio C HamanoJun 12, 2008
  35. Stephan BeyerJun 12, 2008
  36. Paolo BonziniJun 13, 2008
  37. Stephan BeyerJun 13, 2008
  38. Paolo BonziniJun 13, 2008
  39. Olivier MarinJun 13, 2008
  40. Jakub NarebskiJun 12, 2008
  41. Stephan BeyerJun 12, 2008

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.