Steps BEFORE you start work
-
git pull in your main (so that the latest work is in your main)
- type git pull
-
Git switch to your own branch (so that the latest work is copied into your branch)
- type git switch
- type git branch to check
- type git merge (So that if you have pull info into your main from the remote and now your local main is different from your branch, you want to merge your branch with your main)
-
Do your work in your own branch
-
Once done git add. and git commit (so that changes go up into the staging area)
-
git switch to main branch (so that your changes are reflected in the main branch)
-
git pull (changes by other users can be reflected)
-
git merge (combine your work in your main with the others)
-
git push origin main (push local data up to the remote)