Applicable to the situation where there is no project in the remote warehouse and there is a project locally
1. Create a project in the remote warehouse and get the ssh path under the project name
2. Operation in the command window of the local project:
git init initializes the project
git status View project status
git checkout -b dev creates the dev branch
git status to see if it is currently in the dev branch
git remote add origin ssh://[email protected]:20022/ui-component/ui-widget-pallete.git [sshURLxxx]
git add . Add all files in this project
git commit -m "message" save the file and add this save information
git push -u origin dev Create a dev branch for the remote and submit the code at the same time
git checkout -b master creates the master branch
git status to see if it is currently in the master branch
echo readme > readme.md Create a makedown file called reame under the folder where the master branch is located, and the content of the file is readme
git add . Add all files [actually just a readme]
git commit -m "readme"
git push -u origin master creates the master branch for the remote and submits the code at the same time
git status View current branch
git checkout dev switches back to the dev branch for development