From: Jon Smirl Date: Fri, 18 Jul 2008 17:45:41 GMT Subject: Re: [StGit PATCH] Test that we can add a new file to a non-topmost patch with refresh -p Message-ID: <9e4733910807181045mb19ab1dxaaa76696db294ddf@mail.gmail.com> In-Reply-To: <20080718180109.GA14825@diana.vm.bytemark.co.uk> On 7/18/08, Karl Hasselström wrote: > On 2008-07-18 19:03:06 +0200, Karl Hasselström wrote: > > > We currently can't -- this is bug 12038, found by Jon Smirl. See > > > > https://gna.org/bugs/index.php?12038 > > OK, the problem is that to pop the patches on top of the one we are to > refresh, we call pop_patch(keep = True). This in turn calls > git.switch(keep = True), which resets the index (but is careful to not > touch the worktree). > > I'm not quite sure how to fix this in a simple way -- the code simply > assumes that the index contains nothing of interest. And since I > already have a rewrite of refresh that handles this and a handful of > other cases that the old code does not, I'm kind of disinclined to > undertake a larger restructuring of the code. It's no big deal to me, it is easy to work around. But it did take me a while to notice that the add was missing. When is the refresh rewrite going to be ready for prime time? > > Catalin, what do you think? > > > -- > Karl Hasselström, kha@treskal.com > www.treskal.com/kalle > -- Jon Smirl jonsmirl@gmail.com