Created
September 4, 2013 06:49
-
-
Save Dru89/6433491 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
ORIGIN_GIT_REPO=/path/to/my/origin/repo.git | |
############################### | |
# Method 1: You don't care if the clone is a repo, you just want the files | |
# (useful for builds/etc that you aren't manually working with) | |
TMP_GIT_CLONE=/path/to/local/clone | |
git clone $GIT_REPO $TMP_GIT_CLONE | |
# if you do some build logic, it could go here like: | |
# cd $TMP_GIT_CLONE/ | |
# make | |
# make install | |
# rm -rf $TMP_GIT_CLONE | |
exit | |
############################### | |
# Method 2: You actually use the clone like a repo. | |
# (useful for just syncing up another workspace) | |
PATH_TO_OTHER_REPO=/path/to/local/other | |
cd $PATH_TO_OTHER_REPO | |
git pull --rebase | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment