What do you want to save?
Add Code snippet
New code examples
-
TypeScript 2022-02-01 04:10:56
move commits to another branch
# Note: Any changes not committed will be lost. git branch newbranch # Create a new branch, saving the desired commits git reset --hard HEAD~3 # Move master back by 3 commits (Make sure you know how many commits you need to go back) git checkout ne... Add solution -
Shell/Bash 2022-01-31 06:36:43
deploy react express to github pages
Make sure you have already created a repo in github. In "package.json" file of project add - "homepage": "https://username.github.io/reponame" Run Install - "yarn add gh-pages" In "package.json/scripts" ad... Add solution -
Shell/Bash 2022-01-23 05:46:29
git branch from commit
# Create a new branch from previous commit's hash git branch develop 04c900c # Push the new branch to remote repository git push --set-upstream origin develop # Checkout the new branch git checkout develop Add solution -
Shell/Bash 2021-09-25 06:50:03
"git checkout -b" example
# git checkout regarding branches switch git checkout <branch_name> # will take you to that branch git checkout -b <new_branch> # will create a new branch based on the branch you are already in # if this branch already exists then you will ... Add solution
Best helpers
Arad
+5
JoshuaFicy
+5
Majte
+5
Entrepreneur
+5
Meital Regev
+5
Shenkwen
+5
Digcoal
+5
A G Davey
+5
NeuronQ
+5
Emmet
+5
Muazam
+5
Vigrond
+5
Scoiattolo
+5
Erica Price
+5