Skip to content

Instantly share code, notes, and snippets.

View mcpark3141's full-sized avatar

Myoung-Chul Park mcpark3141

View GitHub Profile
@samdeane
samdeane / fixgit.sh
Created August 19, 2012 13:26
Script to move a git repo containing absolute gitdir and worktree submodule paths
#!/usr/bin/env bash
# Fix up a git repo containing submodules that have absolute paths which have changed.
#
# Note that this doesn't do the *proper* fix, which is to turn the absolute paths into
# relative paths. This is possible, but would require a lot more logic because the relative
# paths would be different in each case.
#
# What it does instead is a pragmatic workaround, which is to search & replace the old
# path with a new (and presumably correct) one. This will get you up and running again.