|
From: Ross S. <ros...@ny...> - 2008-07-17 15:13:05
|
On Jul 17, 2008, at 10:56 AM, Michael Schidlowsky wrote: > On Thu, Jul 17, 2008 at 3:24 AM, Ross Snyder <ros...@ny...> > wrote: >> Hey gang, I made those changes related to how we create GitFile/ >> GitDirectory objects. It's in review here: >> >> http://linserv3.cims.nyu.edu:11000/cru/Javagit-4 >> >> Please throw me some feedback. James - I haven't finished yours that >> I started Tuesday - will do so tomorrow, but if you'd like to just >> close it out and keep moving, that's a-okay by me. >> >> Please note that I still haven't mastered the art of checking in just >> my stuff (I merged trunk into my code review branch, which had grown >> stale, and when I checked it all in, I got some of Max's changes in >> my commit too). What should I have done in this case? >> >> -- I made a new branch on Monday >> -- I made my changes today >> -- A bunch of changes were made between Monday and now to trunk >> -- I merged head of trunk into my code review branch, which already >> had my changes >> -- I resolved a bunch of conflicts >> -- I committed the final product >> >> Without something like a git-stash, how do I merge the updated trunk >> stuff into my branch and commit it in a separate commit without >> losing the work I've already done in my branch? > > There's no easy answer to merging code into a stale client that has > lots of your own changes in it. Even git-stash wouldn't help you. At > some point someone has to reconcile the set of changes you're making > with the set of changes made on the repository. That having been > said, if you merged properly you shouldn't have lost any of your local > work. I was thinking git stash would've allowed me to: - stash away my current changes - merge trunk into my branch - commit - un-stash my changes, resolve conflicts - commit Would that work? That way, at least the 2nd commit would be solely my stuff. As it stands, some of the changed lines in my code review are actually changes other people made to trunk. |