I initialized a bare repository on my shared drive and cloned it onto my local drive. I make changes locally, add it, commit it, and push it (git push origin master
). I do the same thing on another computer and just git pull
to get any changes between computers. I am trying to learn how I would revert back to an old "version" of my code in case I needed to.
First I checkout
git checkout "commit #"
then I try to git add -A
and git commit -m "msg"
When I git push origin master
I get "everything is up to date" and when I git checkout master
and try to pull the old changes on the master it doesn't get them. Any idea on how I can get this to work?