From: Ramkumar Ramachandra Date: Sat, 09 Feb 2013 12:25:26 GMT Subject: [BUG] can't switch branches with submodules Message-ID: 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?