git clean не удаляет подмодуль, добавленный в ветку при переключении веток

Как избавиться от подмодулей при переключении веток. Я не понимаю, почему Git Clean говорит, что он удалил подмодуль, но не делает. Это ошибка? Ниже приведены шаги вырезать и вставить для воспроизведения.

git --version
git version 1.7.8.4

git init submod
cd submod
echo "This is a submodule" > README.txt
git add .
git commit -m "Initial commit"
cd ..
git init prog
cd prog
echo "This is a program" > README.txt
git add .
git commit -a -m "Initial commit"
git checkout -b topic1
git submodule add ../submod
git commit -m "Added submodule"

git checkout master
#warning: unable to rmdir submod: Directory not empty
#Switched to branch 'master'

git status
# On branch master
# Untracked files:
#   (use "git add <file>..." to include in what will be committed)
#
#       submod/
#nothing added to commit but untracked files present (use "git add" to track)

git clean -fd
#Removing submod/

git status
# On branch master
# Untracked files:
#   (use "git add <file>..." to include in what will be committed)
#
#       submod/
#nothing added to commit but untracked files present (use "git add" to track)

Ответы на вопрос(1)

Ваш ответ на вопрос