Hi, On Fri, 1 Dec 2006, Anand Kumria wrote: > On Fri, 01 Dec 2006 03:38:13 -0800, Junio C Hamano wrote: > > > Peter Baumann <Peter.B.Baumann@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx> > > writes: > > > >> I don't think it belongs in the plumbing, the git-update-index but I > >> think something like this would be very usefull. > >> > >> AFAIR darcs has this functionality. It selectively ask for each hunk if > >> it should be commited. This would be awfull to have in git. > > > > I concur, on both counts. My own now-defunct Porcelain had the > > darcs style interactive hunk selection because it felt so > > useful (and sometimes it was). > > Is there a good receipe on how to do this? Everytime I do it, I try a > different method; since I'm testing out my understanding of things. > > It'd nice to have some of these "advanced receipes" that people often do > noted down somewhere. Can't say anything about advanced recipes, but I use a poor-man's workflow: $ git diff > a1.patch $ vi a1.patch <edit out what I want to _keep_> $ git apply -R < a1.patch <test & commit> $ git apply < a1.patch Of course, you could write a little wrapper around it, even one which asks you which hunks you want to edit out. Should not be that hard... Note that this is independent of the SCM you are using. Ciao, Dscho - To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html