Re: squashing patches

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

> > Example:
> > 	pick ea7beef
> > 	edit		# or "pause" as you suggested
> > After a little discussion this became:
> > 	pick --edit ea7beef
> >
> > And I can't objectively say what's better
> 
> Me neither.  My "expectation" came primarily from what I understood,
> namely you seemt to prefer atomism, and not from "I want things to be this
> way".

Yes I prefer atomism, because it helps to keep things simple and stupid.

> If we think any proposed and future instruction would be reasonable to
> have --edit option, then all insn implementation would need to support
> "edit" option anyway, and the users do not have to remember which insn
> does and does not support --edit

Currently every insn where it makes sense (indeed, this may be
subjective) does support --edit.  So currently "file" (or "patch"),
"pick", "merge" and "squash" do, because they commit something.

But you are right (and I think Peff meant the same), that the separate
insn is more generic and thus it's more flexible.

So would you prefer a)"pause" or b)"edit"?
Or as text:
a)
edit [<commit>]::
	Pauses the sequencer process to let you manually make changes.
+
After you have finished your changes and added them to the index,
invoke `git-sequencer --continue`.
If you only want to edit the last commit message with an editor,
run `git commit --amend` (see linkgit:git-commit[1]) before.
+
If `<commit>` is given, pick `<commit>` first. This is a short form for
`pick <commit>` and `edit` on separate lines.)

b)
edit <commit>::
	Picks a commit and pauses the sequencer process to let you
	make changes.
+
This is a short form for `pick <commit> and `pause` on separate lines.

pause::		# (perhaps options may occur later, if they make sense)
	Pauses the sequencer process to let you manually make changes.
+
After you have finished your changes and added them to the index, 
invoke `git-sequencer --continue`.
If you only want to edit the last commit message with an editor,
run `git commit --amend` (see linkgit:git-commit[1]) before.


More flexible and modular seems to be the approach b).
But I want your opinion to go sure. ;-)

> I see.  Not using count but setting an explicit mark and using that commit
> sounds more robust, considering that use case.

So I take the --up-to syntax from Paolo?
Seemed right to me.

> >>  - The "tag" command looked a little out of place;
> >
> > Eh, why?
> 
> Why not?

Because it's practical.
The marks are only available during sequencer process and it's just
useful to tag something that you can reach by that name afterwards
(or during sequencing, too).
The user could use tag instead of mark if he wants to keep the ref
after sequencing.
I also can imagine sequencer-using scripts, that want to tag a version
release or something.

> I just wondered why there was a support only for lightweight tag there.

Basically because it's in next :)
And then I thought "Ok, nice. Let's keep it.".

> You do not have "branch" command, and your "tag" command does not seem to
> support things like -a, -s, -m<msg>, etc.

Hmmm, -a, -s and -m could even be useful.

Regards,
  Stephan

-- 
Stephan Beyer <s-beyer@xxxxxxx>, PGP 0x6EDDD207FCC5040F
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux