Created
May 21, 2010 08:43
-
-
Save jon/408631 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
if ! [ "$#" = "1" ]; then | |
echo "Usage: $0 <submodule name>" | |
exit 1 | |
fi | |
name="$1" | |
path=$(git config -f .gitmodules submodule."$name".path) | |
git config --remove-section submodule."$name" | |
git config -f .gitmodules --remove-section submodule."$name" | |
git rm --cached "$path" | |
rm -rf "$path" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment