help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: Committing only specific hunks in VC


From: Colin S. Miller
Subject: Re: Committing only specific hunks in VC
Date: Wed, 12 Jan 2011 21:06:20 +0000
User-agent: Mozilla-Thunderbird 2.0.0.24 (X11/20100328)

Oleksandr Gavenko wrote:
On 11.01.2011 7:40, Deniz Dogan wrote:
I have a bunch of files that have been modified and I'd like to commit
all of these changes except for one hunk in one of the files.

How would I do this from Emacs? I've heard that it's possible to stage
only specific hunks in magit, but I'm using Mercurial.

I usually save common patch in '.diff' like file.


I'd do something similar, when I need to do this in CVS.

I copy the entire tree, and then on the copy use #
M-x cvs-mode and 'd e' to locate the changes I want to remove.

Then I commit from this tree, and afterwards update the original tree.
Patch normally makes a good job of figuring out what to do, unless
one of the non-commited hunks is right beside a commited hunk,
in which case I'd normally delete the original hunk in the conflict and
use 'd e' to decide what parts of the modified hunk to keep.


HTH,
Colin S. Miller
--
Replace the obvious in my email address with the first three letters of the 
hostname to reply.


reply via email to

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