git global setup
git config --global --edit // modify git config fileor// config username and emailgit config --global user.name "scn4006"git config --glboal user.email "dongguang.zhu@saurer.com"// delete username and passwordgit credential-manager uninstallgit config --global credential.helper wincred## Git store username and passwordgit config --global --unset credential.helper // 删除用户名和密码git config --global credential.helper store
Create a new repository
git clone git@172.16.34.200:root/spc.gitcd spctouch README.mdgit add README.mdgit commit -m "add README"git push -u origin master
Push an existing folder
cd existing_foldergit initgit remote add origin git@172.16.34.200:root/spc.gitgit add .git commit -m "Initial commit"git push -u origin master
Push an existing Git repository
cd existing_repogit remote rename origin old-origingit remote add origin git@172.16.34.200:root/spc.gitgit push -u origin --allgit push -u origin --tags