I messed up with Git-flow... help!

Hey,

I made a local commit and tried pushing it to bitbucket. It didn't work so I started playing around.. I hit git-flow and hit the default option and OK.. Now all my code has reverted to the original! I've lost all my hour's work...

Is there a way to switch back to pre-git-flow??

2 answers

1 accepted

I got it back! I didn't stash it or anything...

I found the head ref. no of the old commit in one of the files in .git folder and manually changed the actual head to that code. And boom.

Whew. Moving to a mac is painful.

Ouch.

I hate to be the harbringer of bad news, but I think that your lost commit is hosed. Did you stash or anything before you did it?

I got it back! I didn't stash it or anything...

I found the head ref. no of the old commit in one of the files in .git folder and manually changed the actual head to that code. And boom.

Whew. Moving to a mac is painful.

Yay! Glad you got your stuff back.

I've been on a mac professionally for years now. After you get used to it... I swear I get a lot more work done than when I was on windows. Maybe it's just selection bias.

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Published May 30, 2018 in Sourcetree

Tip from the team: configuring Git or Mercurial in Sourcetree

Supported Platforms macOS Windows To make using Sourcetree as simple yet powerful as possible we embed (bundle) dependencies such as Git, Git LFS, and Mercurial. We strive to keep these...

387 views 0 1
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you