Meanwhile codes and code uploaded to the cloud github

Currently there is a large platform git domestic gitee, foreign github

So how do you upload both in the local warehouse to the two platforms do?

Right under the first project directory selection Git Bash Here:

If not, then install Git Bash Here's the address: https: //tortoisegit.org/download/

The following is a specific operation:

// delete the associated remote named origin of the library:

>git remote rm origin

// associated gitee remote git repository gitee_demo association Address: https://gitee.com/xxx/demo.git

>git remote add gitee_demo https://gitee.com/xxx/demo.git

// github associated remote git repository github_demo association Address: https://github.com/xxx/demo.git

>git remote add github_demo  https://github.com/xxx/demo.git

// Check to see remote local libraries connected

>git remote -v

It will be displayed:

gitee_demo [email protected]:xxx/demo.git(fetch)

gitee_demo [email protected]:xxx/demo.git(push)

github_demo [email protected]:xxx/demo.git(fetch)

github_demo [email protected]:xxx/demo.git(push)

// push command

// push github:

>git push github_demo  master

// Push gitee:

>git push gitee_demo master

If you right-master-> pushed, you will find github_demo and gitee_demo options in the sourcetree

Then select a remote database will be uploaded to the appropriate library, of course upload process if you do not set off the account password, you'll be prompted to re-box settings

Published 100 original articles · won praise 5 · Views 390,000 +

Guess you like

Origin blog.csdn.net/jinxinxin1314/article/details/104572140
Recommended