Skip to content

How to make a PR

Michael Nareg Arabian edited this page Feb 1, 2021 · 1 revision

Steps to creating a branch, and making a pull request (PR):

git checkout main ----> make sure you are on the master branch

git pull ----> pulls the most recent version of master so your new branch is up to date

git branch ----> create a new branch with format: Name/ ex: Patrick/login-feature

git checkout ----> checkout your newly created branch

make changes

git add . ----> stage all changes

git status ----> check current branch status

git commit -m "branchname" ----> commit changes to local branch

git push origin ----> pushes changes to your remote branch to be merged into master

in github, make a pull request (branches > active branches > > New pull request)

when done with branch (PR HAS BEEN MERGED INTO MASTER), delete it

delete it locally using: git branch -d delete remote branch in github "branches" section steps 3 & 4 can be combined into a single command: git checkout -b this creates a new branch and switches to it

if you wish to only stage some files (not all): git add

Clone this wiki locally