I want to restore all my files to a commit.
I'm doing:
git checkout commit
on remote server and files are restored
what exactly should i do after it on local and remote?
Do i need to create new branch and merge ?
I want to restore all my files to a commit.
I'm doing:
git checkout commit
on remote server and files are restored
what exactly should i do after it on local and remote?
Do i need to create new branch and merge ?
If you want to reset your current branch to some commit, then use:
git reset --hard <some commit hash>
Keep in mind that this will move the entire HEAD to this other commit, thereby wiping out your working directory and stage. Only use this option if you are certain that you really want to do this.