1.全局设置
编辑用户名等信息
git config --global user.name "yourname"
git config --global user.email "yourname@qq.com
2.创建新仓库
git clone https://git.yy.com/xx/xxx.git
cd 文件夹
touch README.md
git add README.md
git commit -m "add README"
git push -u origin master
3.推送已有文件夹
cd existing_folder
git init
git remote add origin https://git.yy.com/xxx/xxx.git
git add .
git commit -m "Initial commit"
git push -u origin master
4.推送已有仓库
cd existing_repo
git remote rename origin old-origin
git remote add origin https://git.yy.com/xxx/xxx.git
git push -u origin --all
git push -u origin --tags