Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SHELL

github cancel last push

# to undo a git push
git push -f origin HEAD^:master

# to get to previous commit (preserves working tree)
git reset --soft HEAD

# to get back to previous commit (you'll lose working tree)
git reset --hard HEAD^
 
PREVIOUS NEXT
Tagged: #github #cancel #push
ADD COMMENT
Topic
Name
5+2 =