SourceTree won't discard changes, can't unshelve stored diff

Rick Herrick August 22, 2013

I have a major issue with the newest version of SourceTree for Windows, 1.1.0.0. I added an existing repository to SourceTree (I had recently rebuilt this machine and hadn't installed SourceTree on it yet since I didn't know Mercurial support had finally been added). I had a bunch of new commits to pull before I could commit my latest changes, so I went ahead and shelved my changes. I then pulled and updated.

The problem is that, once I updated, SourceTree is convinced that two of the files in the repo are modified. They're not, but I can't make it go away. I've tried discarding the changes repeatedly, both in SourceTree and on the command line, but they continue to show as modified. The big problem is that now I can't unshelve my changes.

This is probably a result of line ending issues, but regardless of what the cause is, it needs to be handled properly, that particular issue being a well known problem between Windows and *nix systems. I've tried any number of things, but can't get this to work. I created a short screen cap showing the problem: http://screencast.com/t/cgxvi6wcE.

Luckily I anticipated that there might be an issue and backed up my changes elsewhere, so all I had to do was copy them back into the repo. After that, the commit went fine and I was able to push up to Bitbucket. And after that, SourceTree doesn't show any "modified" unmodified files so things seem OK. But it definitely makes me leery of trusting my changes to the shelf without backing them up elsewhere.

So this is really probably just a bug and should be filed as such, but all the links try to push me here instead of the bug tracker, so I'll give this a go first...

3 answers

1 accepted

0 votes
Answer accepted
Rick Herrick August 22, 2013

So this problem re-occurred outside of SourceTree just now, so I had to track it down.

It looks as if something (and I'm thinking SourceTree, because this only happened after today's update) added the eol extension to my .hgrc file (or mercurial.ini, I'm not clear as to which would take precedence and I went through both of them; no, I didn't install both of them, but various tools over time have decided I needed one or the other in particular). I don't think it was the eol= declarator in and of itself: I think it was the [eol] configuration section with a couple of entries for cleverencode. I didn't even know those options existed, so I know that I didn't add them in there! Once I removed those, the problem went away.

If SourceTree does add those cleverencode bits, it might be a good idea to NOT do that, because, at least with the version of Mercurial on my system, it seems to cause this issue, which is a real blocker.

0 votes
Artem Kuznetsov March 10, 2016

Have same issue

0 votes
Thiago Ramalho October 13, 2015

Did someone found a solution for this?

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events