全局设置
git config --global user.name "用户名"
git config --global user.email "xxx@126.com"
创建 git 仓库:
mkdir dsa_zheda
cd dsa_zheda
git init
touch README.md
git add README.md
git commit -m "first commit"
git remote add origin https://gitee.com/xxx/dsa_zheda.git
git push -u origin master
已有仓库?
cd existing_git_repo
git remote add origin https://gitee.com/xxx/dsa_zheda.git
git push -u origin master
来源:oschina
链接:https://my.oschina.net/u/568675/blog/4331109