I have errors in my code and I would like to be able to return to a commit
specific one and be able to return it master
, how can I do it?
this is mycommit
commit 70b0aecf7ee7bfb4864eab75e56ccd67426926f1
Author: emeery <[email protected]>
Date: Tue Apr 3 23:48:28 2018 -0500
cabecera estrategias
First make a
git reset - - hard {commit}
Once the reset is done, to upload it as a master you must force the push, since in the remote it is already uploaded a few levels above that commit
This should work:
git reset --hard {id_commit}
then you must push to your repo: gitpush -f <remote> <branch>