The easiest way to find the head commit of a branch is using the following commands.
git reflog
and to reset the current branch to it with -- hard option, if suppose old commit was HEAD@{1} in reflog then follow the commands
git reset --hard HEAD@{1}
If you are using windows system then you need to quote it “HEAD@{1}”.
History of the old commit can find in
git log HEAD@{1}
If you've not disabled per branch reflogs
git reflog branchname@{1}
As rebase detaches the branch head before reattaching to the final head.
For more commands like this please go through the following tutorial that will help you understand the git