2016-10-23 70 views

回答

0

如果你有一個本地回購推到遠程回購,並希望第二遠程回購進行更新,你需要設置在第一個遠程回購一post-update hook(如this answer for instance

ssh [email protected] 
cd /path/to/remote/repoA.git/hooks (#bare repository) 
git remote add B /url/to/remote/bare/repoB.git 
echo "git push --mirror B" > post-receive 
chmod 755 post-receive 
相關問題