# [BUG] can't switch branches with submodules

2 messages from 2013-02-09 to 2013-02-09. Participants: Ramkumar Ramachandra, W. Trevor King.
Thread: https://gitlist.dev/t/32868

## Ramkumar Ramachandra, 2013-02-09 12:25

Subject: [BUG] can't switch branches with submodules
Message-ID: <CALkWK0=aifKVHnPZSfqE0rLn1aUGqC0nBULaLCe6UY2=6YGZ9g@mail.gmail.com>
URL: https://gitlist.dev/e/CALkWK0%3DaifKVHnPZSfqE0rLn1aUGqC0nBULaLCe6UY2%3D6YGZ9g%40mail.gmail.com

```
Hi,

I have two branches: master and gh-pages.  master has one submodule
called foo that gh-pages doesn't.  When I try to check out gh-pages
from master:

    warning: unable to rmdir foo: Directory not empty

And the foo directory exists in my worktree.  This is very annoying,
and I want to fix it now.  Where is this error coming from?  How does
the worktree get updated when I checkout?

```

## W. Trevor King, 2013-02-09 12:32

Subject: [BUG] can't switch branches with submodules
Message-ID: <20130209123205.GC1795@odin.tremily.us>
URL: https://gitlist.dev/e/20130209123205.GC1795%40odin.tremily.us
In-Reply-To: <CALkWK0=aifKVHnPZSfqE0rLn1aUGqC0nBULaLCe6UY2=6YGZ9g@mail.gmail.com>

```
On Sat, Feb 09, 2013 at 05:55:26PM +0530, Ramkumar Ramachandra wrote:
> I have two branches: master and gh-pages.  master has one submodule
> called foo that gh-pages doesn't.  When I try to check out gh-pages
> from master:
> 
>     warning: unable to rmdir foo: Directory not empty
> 
> And the foo directory exists in my worktree.  This is very annoying,
> and I want to fix it now.  Where is this error coming from?  How does
> the worktree get updated when I checkout?

You may want to look at the pending Great Submodule Integration
Branch:

On Mon, Jan 07, 2013 at 07:59:53AM +0100, Jens Lehmann wrote:
> I´m currently working on teaching mv to move submodules and intend
> to send those patches to the list after finishing submodule deinit.
> Please see
>   https://github.com/jlehmann/git-submod-enhancements/commits/mv-submodules
> for the current state of this series.

;)
Trevor

-- 
This email may be signed or encrypted with GnuPG (http://www.gnupg.org).
For more information, see http://en.wikipedia.org/wiki/Pretty_Good_Privacy

```
