Created
December 1, 2014 14:06
-
-
Save bendikro/1e1975a0b84a497d758d to your computer and use it in GitHub Desktop.
Update remote git repos
This file contains 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
#!/usr/local/bin/bash | |
GIT=/usr/local/bin/git | |
REPO_DIR=/home/bro/programmer/deluge/deluge_cron_update | |
BRANCHES=(develop 1.3-stable) | |
UPDATE_REPOS=(github deluge-github) | |
cd $REPO_DIR | |
$GIT remote update | |
for branch in ${BRANCHES[*]} | |
do | |
$GIT checkout $branch && $GIT merge remotes/deluge/$branch | |
for repo in ${UPDATE_REPOS[*]} | |
do | |
$GIT push $repo $branch | |
done | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment