Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

how to revert back to previous commit in git

# This will destroy any local modifications.
# Don't do it if you have uncommitted work you want to keep.
git reset --hard 0d1d7fc32

# Alternatively, if there's work to keep:
git stash
git reset --hard 0d1d7fc32
git stash pop
# This saves the modifications, then reapplies that patch after resetting.
# You could get merge conflicts, if you've modified things which were
# changed since the commit you reset to.
Comment

github restore previous commit

# syntax
git revert <commit>
# example
git revert 99a5c5905e12c74725bae64c61efce140662ce24
# where 99a5c59... is the commit (you can check it on github)
Comment

PREVIOUS NEXT
Code Example
Shell :: nano line number 
Shell :: docker remove container 
Shell :: ionic capacitor motion 
Shell :: look like hacker linux 
Shell :: haskell change version 
Shell :: install and import gsap in vue 
Shell :: ubuntu upgrade certbot acme v2 
Shell :: bash function arguments 
Shell :: install github cli ubuntu 
Shell :: linux change owner 
Shell :: bash if is symlink 
Shell :: git merge with message 
Shell :: git push an existing repo from cmd/bash 
Shell :: tmux kill all sessions 
Shell :: install node and npm ubuntu 
Shell :: php install extension 
Shell :: kde up maxfps 
Shell :: download kubectl for windows 
Shell :: print in shell script 
Shell :: running splash in docker command line 
Shell :: install node package globally 
Shell :: installer microsoft teams ubuntu 
Shell :: Finding path to some ruby versions 
Shell :: angular full installation guide 
Shell :: benchmark a network drive windows without installing 
Shell :: git remove added file to commint 
Shell :: PowerShell command list software windows server 2016 
Shell :: execute command over ssh 
Shell :: git local setup 
Shell :: how to compile 64 bit nasm 
ADD CONTENT
Topic
Content
Source link
Name
9+8 =