Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

git undo merge

git reset --hard HEAD~1
Comment

Undo git merge

git reset --merge HEAD~1
Comment

git revert merge

git revert -m 1 <merge-commit>
Comment

revert last merge git

git revert -m 1 commit_hash
Comment

git undo merge

git reset --hard HEAD~1
git reset --hard <commit_sha>
Comment

how to revert a merge locally

git reset --hard <cbm>

where cbm is the commit number before the merge you want to revert
to get a list of all the merges you can use the following line

git log --graph

and then use the commit number from the one before the merge you want to revert
Comment

undo merge

// find the commit hash
git log --oneline

git revert -m 1 [commit-hash]

// https://www.datree.io/resources/git-undo-merge
Comment

revert local merge

git reset --merge origin/master
Comment

PREVIOUS NEXT
Code Example
Shell :: change file permission linux 
Shell :: start beef kali linux 
Shell :: download kali linux iso file 64 bit 
Shell :: git change file case windows 
Shell :: openssl check certificate expiration 
Shell :: docker redis set username and password 
Shell :: git create tag and push 
Shell :: cp command exclude files 
Shell :: node modules folder not getting ignore in git 
Shell :: log cpu usage on linux 
Shell :: add ssh github 
Shell :: linux alias 
Shell :: how to delete evicted pod in kubernetes: 
Shell :: openssl serial number 
Shell :: nuxt new project npm 
Shell :: install composer debian 
Shell :: mac see current path7 
Shell :: Finding path to some ruby versions 
Shell :: how to check pyqt version 
Shell :: how to install yagmail 
Shell :: bash how to delete blank lines 
Shell :: crosh 
Shell :: bash inline countdown 
Shell :: how to add images in readme github 
Shell :: install yarn on ubuntu 
Shell :: copy file to ubuntu server 
Shell :: delete all files in a directory command 
Shell :: sum bash 
Shell :: Regex: Match Last Occurrence aka Negative Lookbehind 
Shell :: scp file download 
ADD CONTENT
Topic
Content
Source link
Name
1+3 =