bug-patch
[Top][All Lists]
Advanced

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

[bug-patch] Is there a way to make patch not so strict?


From: Yuri Kanivetsky
Subject: [bug-patch] Is there a way to make patch not so strict?
Date: Sat, 5 Dec 2015 20:05:58 +0200

Hi,

The big picture is I'm trying to "port" "commit not all the changes"
workflow from git to svn. In git there is an interactive staging
thing, where you can chose what to commit. Namely, you can chose
files, hunks, or parts of hunks, or even edit a hunk and commit what
wasn't in the hunk at all. This way you can commit the changes as
several commits.

With svn I'm thinking about creating a patch and breaking it into
several patches. Let's have something to look at:

    diff --git a/1 b/1
    index dbee026..5c89250 100644
    --- a/1
    +++ b/1
    @@ -1,2 +1,5 @@
    aaa
    +111
    +222
    +333
    bbb

The issue here is that after applying and committing the first patch,
you should alter `@@ -1,2 +1,5 @@` lines in the rest of the patches
for them not to be taken as malformed patches.

Is there a way to make patch more tolerant to what's in the header of
a hunk? Or more or less easy way to automatically recalculate the
values? Any other suggestions?

More info here:
http://unix.stackexchange.com/questions/247425/how-to-make-patch-not-so-strict

Regards,
Yuri



reply via email to

[Prev in Thread] Current Thread [Next in Thread]