Code to remember while using git bash
Go to file
- cd (file name)
Go back
- cd ..
to clone
- git clone (SHH Link)
make folder
- mkdir (name of folder)
make branch
- git checkout -b "Shreejan"
- git checkout Shreejan
add something
- add (file name)
add all
- add .
commit
- git commit -m "..."
push
- git push
- git push --set-upstream origin Shreejan
go to main branch
- git checkout main
pull
- git pull
merge
-
git merge Shreejan
-
(if merge still busy) git commit -m "merge complete"
-
push again
delete branch
-
git branch -d Shreejan
-
git branch -D Shreejan
-
git branch -a
-
git branch -d Shreejan
-
git push origin --delete Shreejan
-
git checkout -b Tim