Skip to content

Instantly share code, notes, and snippets.

@abhitrueprogrammer
Created March 12, 2025 20:11
Show Gist options
  • Save abhitrueprogrammer/b18110f47338f9e71fe07b5dd9873e92 to your computer and use it in GitHub Desktop.
Save abhitrueprogrammer/b18110f47338f9e71fe07b5dd9873e92 to your computer and use it in GitHub Desktop.
github Current flow
git config --global user.name "Your Name"
git config --global user.email "[email protected]"
git config --global init.defaultBranch main
ssh-keygen -t ed25519 -C <youremail>
cat ~/.ssh/id_ed25519.pub
#copy the whole output
#Add SSH key to github [https://github.com/settings/keys]
existing:
git clone [email protected]:USER-NAME/REPOSITORY-NAME.git
---
new:
git init -b main
git add . && git commit -m "init"
gh repo create
-> add existing
---
git push
#branching
git checkout -b test
git add .
git commit -m "msg"
git push
# merge
git main
git pull
git checkout test
git merge main
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment