git同時(shí)push到多個(gè)倉(cāng)庫(kù)

為防止一個(gè)git倉(cāng)庫(kù)由于各種原因造成無(wú)法訪問(wèn),可以將代碼push到多個(gè)倉(cāng)庫(kù)。

編輯本地倉(cāng)庫(kù)目錄下面的.git目錄下的config文件。

添加:

[remote "all"]
url = git@github.com:licess/licess.git
url = git@gitcafe.com:licess/licess.git

再push時(shí),運(yùn)行g(shù)it push all master

發(fā)表評(píng)論

(required)

This site uses Akismet to reduce spam. Learn how your comment data is processed.