Re: [PATCH v2 0/8] cherry-pick: add `--empty`

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

 



Hi Brian

On 10/02/2024 07:43, Brian Lyles wrote:
The ultimate goal of this series is to allow git-cherry-pick(1) to
automatically drop redundant commits. The mechanism chosen is an
`--empty` option that provides the same flexibility as the `--empty`
options for git-rebase(1) and git-am(1).

Some secondary goals are to improve the consistency in the values and
documentation for this option across the three commands.

See "Does extending `--empty` to git-cherry-pick make sense?" [1] for
some context for why this option is desired in git-cherry-pick(1).

[1]: https://lore.kernel.org/git/CAHPHrSevBdQF0BisR8VK=jM=wj1dTUYEVrv31gLerAzL9=Cd8Q@xxxxxxxxxxxxxx

Along the way, I (with some help from Elijah and Phillip) found a few
other things in the docs and related sequencer code to clean up.

Thanks for the revised patches - they are looking good and were a pleasant read. I've left a few small comments, my main concern is the change to `--keep-redundant-commits` in patch 6 which I'm not sure is really worth the disruption.

Best Wishes

Phillip

Brian Lyles (8):
   docs: address inaccurate `--empty` default with `--exec`
   docs: clean up `--empty` formatting in git-rebase(1) and git-am(1)
   rebase: update `--empty=ask` to `--empty=drop`
   sequencer: treat error reading HEAD as unborn branch
   sequencer: do not require `allow_empty` for redundant commit options
   cherry-pick: decouple `--allow-empty` and `--keep-redundant-commits`
   cherry-pick: enforce `--keep-redundant-commits` incompatibility
   cherry-pick: add `--empty` for more robust redundant commit handling

  Documentation/git-am.txt                    | 20 ++++---
  Documentation/git-cherry-pick.txt           | 30 +++++++---
  Documentation/git-rebase.txt                | 26 ++++++---
  builtin/rebase.c                            | 16 +++--
  builtin/revert.c                            | 40 +++++++++++--
  sequencer.c                                 | 65 +++++++++++----------
  t/t3424-rebase-empty.sh                     | 55 ++++++++++++++++-
  t/t3501-revert-cherry-pick.sh               | 11 ++++
  t/t3505-cherry-pick-empty.sh                | 29 ++++++++-
  t/t3510-cherry-pick-sequence.sh             | 40 +++++++++++++
  t/t3515-cherry-pick-incompatible-options.sh | 48 +++++++++++++++
  11 files changed, 312 insertions(+), 68 deletions(-)
  create mode 100755 t/t3515-cherry-pick-incompatible-options.sh





[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