profile pic

Precise Asteroid

Welcome to Amir's Blog 👋

Git Common flows

2023-06-24

Use Cases

local code to push to github

create a new repo on github and then
// connect a remote to it and push
git remote add origin https://github.com/....git
git push -u -f origin master

create a branch

create a new brnach and checkout to it
// create a new branch and checkout to it
git checkout -b branchName
// which is the same as 
git branch branchName
git checkout branchName

simple Merge

inspiration from https://git-scm.com/book/en/v2/Git-Branching-Basic-Branching-and-Merging git merge

Made by Amir 💚