From: Jan Harkes Date: Thu, 16 Jun 2005 16:39:07 GMT Subject: Re: Using local trees and cogito Message-ID: <20050616163907.GA26037@delft.aura.cs.cmu.edu> In-Reply-To: <9e473391050615193719d81951@mail.gmail.com> On Wed, Jun 15, 2005 at 10:37:59PM -0400, Jon Smirl wrote: > One problem I did notice is that if you add file in a fork and jump to > a fork without the file, it doesn't get removed. That's not a big > problem but it can be confusing. I noticed the same thing and 'solved' it the following way, After pointing the head at the new branch, instead of using, git-read-tree -m HEAD && checkout-cache -q -f -u -a I use, git-diff-cache -R -p HEAD | git-apply --index This simple reverse applies the differences between the previously checked out tree and the branch we just switched to. Ofcourse the cache/index has to be up to date before we switch between branches. Jan