Re: Feature Request: Custom split location for `git add --patch`

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

 



Johannes Schindelin <Johannes.Schindelin@xxxxxx> writes:

> Hi Dennis,
>
> On Thu, 16 Jun 2022, Dennis van Gerwen wrote:
>
> ...
> Note how the `-` line became a context line? It _has_ to be, otherwise the
> second hunk could not be applied as-is. That is, until the first hunk has
> been applied. In which case the second hunk needs to be modified:
>
> 	-- snip --
> 	@@
> 	 All journeys start with a first step.
>
> 	+Actually, some journeys, some interesting ones, end in a disaster
> 	+right at the start, because the first step was skipped.
>
> 	 And this concludes the chapter. Good night.
> 	-- snap --
>
> Now the `[tbd]` line in the context has vanished.
>
> This is really an important concept to keep in mind: if you split at
> context lines, your hunks can remain immutable. If you want to split
> elsewhere, after one of the hunks resulting from said split is a applied,
> you have to recompute the other hunk.

Good write-up.



[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