1. Global Settings
Edit user names and other information
git config --global user.name "yourname"
git config --global user.email "[email protected]
Copy the code
2. Create a warehouse
git clone https://git.yy.com/xx/xxx.gitMd git add readme. md git commit -m"add README"
git push -u origin master
Copy the code
3. Push existing folders
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
Copy the code
4. Push the existing warehouse
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
Copy the code