Make Sure you are in the master /main branch because that' what i want to merge to #Git Commands
- git pull origin main *
//this fetches all the code from the remote and it merges it into our mainbranch because that's what we indicated after origin. from the main branch from the remote to our main branch onto our local//
// to preserve the state of the master branch to not edit and potentially mess it up --> Switch to a nex branch
- git checkout -b INSERT_BRANCH_NAME *
//After changes
-
Command:: git add .
-
Command:: git commit -m "Say whatever here"
/make sure you've already checked oyt the branch (git checkout -b INSERT_bBRANCH_NAME)/
-
Command:: git push origin INSERT_BRANCH_NAME
-
Instruction:go to github repository see the new branch and comment on your changes
-
Instruction: click on create pull request
-
Instruction: Assign reviewers
-
case 1:if all reviews are happy with it
- Instruction: click merge pull request that will merge it in the main branch
case 2: if there a review requesting change (suggesting a new feature) /pull down the main branch just in case anyone has done some changes to the branch/
- Command: git checkout main
/updating changes of the main branch in the code/ 2. Command: git pull origin main
/checkout a new branch for the feature/ 3. Command: git checkout -b INSERT_NEW_BRANCH_NAME
- Instruction: Repeat 1-->6