[Ksummit-discuss] [ANNOUNCE] git-series: track changes to a patch series over time

Steven Rostedt rostedt at goodmis.org
Sat Jul 30 02:55:01 UTC 2016


On Fri, 29 Jul 2016 10:57:26 -0700
James Bottomley <James.Bottomley at HansenPartnership.com> wrote:


> I do this too, but I also work with the diff when moving hunks.  What I
> do is:
> 
> git checkout <removal commit>
> git show <removal commit> > tmp.diff
> vi tmp.diff so it only has the hunks I want to remove
> patch -p1 -R < ~/tmp.diff
> git commit --amend -a
> git checkout <add commit>
> patch -p1 < ~/tmp.diff
> git commit --amend -a
> 
> It's a bit cumbersome, but you can script it.  If there are better ways
> to do it, I'm interested.

I do that quite a lot too. But I also use a git quilt mix a bit.

When I get a patch that is based on my work and fails to apply, I do:

quilt import /tmp/ftrace.patch
quilt push -f

see what breaks, and fix it up. Sometimes I have to go and change the
change log, or subject, especially if the patch is from a non native
English speaker, and the change log simply doesn't make much sense
(unless you know what the patch is already doing). Then:

quilt refresh
do-git-am.pl patches/ftrace.patch

Where do-git-am.pl is my script that will add Cc's and Link: tags.

-- Steve
 


More information about the Ksummit-discuss mailing list