Re: pw/add-p-select, was Re: What's cooking in git.git (Dec 2018, #01; Sun, 9)

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

 



Hi Dscho

On 09/12/2018 20:31, Johannes Schindelin wrote:
Hi Junio,

On Sun, 9 Dec 2018, Junio C Hamano wrote:

* pw/add-p-select (2018-07-26) 4 commits
  - add -p: optimize line selection for short hunks
  - add -p: allow line selection to be inverted
  - add -p: select modified lines correctly
  - add -p: select individual hunk lines

  "git add -p" interactive interface learned to let users choose
  individual added/removed lines to be used in the operation, instead
  of accepting or rejecting a whole hunk.

  Will discard.
  No further feedbacks on the topic for quite some time.

That is not quite true. I did comment that this feature

Sorry I meant to reply to that comment but never got round to it.

(which I take as
being inspired by Git GUI's "Stage Selected Line"),

not particularly, I don't use git gui I just wanted a way to easily stage a subset of lines without editing the hunk.

and thought that it would be useful.

I could imagine, however, that it would make sense for `git add -p` to
imitate that feature more closely: by allowing to stage a single line and
then presenting the current hunk (re-computed) again.

that sounds like it would be quite tedious to stage more than a couple of lines, and it could be awkward to get it to stage modified lines correctly (While I was writing the feature I tried git gui, I think it is supposed to be able to stage modified lines correctly but I never persuaded it to do it for me. I also tried gitg, tig and hg commit -i but I couldn't get them to do modified lines either)

I'll try and re-roll in the New Year, when does the outreachy project for converting add -i start? - it would be good to try and get this pinned down before then.

Best Wishes

Phillip
Ciao,
Dscho





[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