SourceTree – Not sure how to go back to a previous commit

So I’m fairly new to version control but managed to setup sourceTree with bitbucket relatively easily.

I also now understanding basic concepts such as commit, push and pull.

  • git rebase using sourcetree
  • No branches in SourceTree
  • automatically rejecting a commit based on certain criteria
  • How to use git command line via SourceTree on Windows
  • GitLab rename branch and start over on another
  • .gitignore exception is including extra files
  • I can’t however find any documentation (that doesn’t involve text commands) on how to revert all my uncommitted changes at once to the last commit (not pushed). I can do it individually for each file but this is taking far too long.

    Many thanks!

  • How can I tell if one commit is an ancestor of another commit (or vice-versa)?
  • GIT SSL error persist despite recommended fix for Mac OS X Yosemite
  • Git clone verbose mode – show each incoming object
  • Cloning a git-svn repository with svn metadata
  • Partial sharing of git repositories
  • In which branch should I build a docker image?
  • One Solution collect form web for “SourceTree – Not sure how to go back to a previous commit”

    Well I have never tried SourceTree, but you are looking for command

    git reset --hard HEAD

    which means reset working tree and index to the state of your latest commit. Looking at some SourceTree screenshorts there are two buttons with same icons that might help you. I guess they have different names in different SourceTree versions. You might want to check what’s behind Reset or Discard button. Look to hard reset to the HEAD commit.

    Git Baby is a git and github fan, let's start git clone.