Commit 69d11d099ddead6e2ef00646ae02cada9f6ab197
1 parent
10d151e8
Exists in
master
and in
1 other branch
Adding sync script.
Showing
1 changed file
with
26 additions
and
0 deletions
Show diff stats
... | ... | @@ -0,0 +1,26 @@ |
1 | +#!/bin/bash | |
2 | +# | |
3 | +# https://help.github.com/articles/syncing-a-fork/ | |
4 | +# | |
5 | +# https://help.github.com/articles/configuring-a-remote-for-a-fork/ | |
6 | +# | |
7 | +# https://www.opentechguides.com/how-to/article/git/177/git-sync-repos.html | |
8 | +# | |
9 | +# Setup: | |
10 | +# | |
11 | +# git remote add github https://github.com/PerryWerneck/pw3270-plugin-hllapi.git | |
12 | +# | |
13 | +# | |
14 | + | |
15 | +git push | |
16 | + | |
17 | +git fetch origin | |
18 | +git checkout master | |
19 | +git merge origin/master | |
20 | + | |
21 | +for repo in $(git remote -v | grep -v origin | grep "(push)" | awk '{print $1}') | |
22 | +do | |
23 | + echo "Updating ${repo} ..." | |
24 | + git push ${repo} | |
25 | +done | |
26 | + | ... | ... |