[SourceTree] How to use a local Mercurial installation?

I have a local Mercurial installation in /sw/bin (more recent than the one used by SourceTree). I made 2 symlinks in /usr/local/bin and /usr/bin but SourceTree doesn't find them when I click on "Utiliser Mercurial Système" (Use System Mercurial?) button in Preferences… . How can I change the Hg binary used by SourceTree?

Thanks,

Antoine

3 answers

1 accepted

Becuase the vast majority of Mercurial is installed in your Python library ('hg' is just a simple script which starts Python and loads the libraries), the location of the hg script isn't actually very useful. So instead, SourceTree invokes Python, imports the mercurial package and asks where it's located. This will work regardless of where the 'hg' script is located - unless your command-line Python install is different to the system install perhaps.

However, this may be academic anyway if you're using hg 1.9, please see http://confluence.atlassian.com/display/SOURCETREEKB/Error+Message+-+Patching+Mercurial+failed . Now that 1.9.3 is out which fixes the nasty merge bug on OS X, SourceTree will support 1.9+ soon - once the extensions that 1.9 broke are updated to work with it.

Thank you for the quick answer. I've forced the use of my Python 2.7 with 1.9.3 Mercurial but SourceTree failed with some private unnamed extensions. I'll wait the next ST release but if I had the list of needed extensions I could try with my local installation?

Regards,

Antoine

You can see the extensions SourceTree uses on the Preferences page - in terms of 1.9 though the main remaining problem is hgattic (for shelve/unshelve). I'm in the process of adapting it for 1.9 because the original author hasn't done it, and I can't find any definitive versions yet - it's in the public domain here: https://bitbucket.org/sinbad/hgattic

I just have a mercurial server started serving all my local repositories to any of my systems including SourceTree and Bamboo.

Hi,

Any news about supporting new mercurial versions? We realy neeed use large files support [2.0 mercurial version] and now it's impossible because SourceTree can't work with such repositories.

Thanks,

SourceTree 1.3 is using Mercurial 2.0 by default, there will be a beta at the end of this week.

"SourceTree 1.3 is using Mercurial 2.0 by default, there will be a beta at the end of this week."

Wow - great

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Piotr Plewa
Published Dec 27, 2017 in Bitbucket

Recipe: Deploying AWS Lambda functions with Bitbucket Pipelines

Bitbucket Pipelines helps me manage and automate a number of serverless deployments to AWS Lambda and this is how I do it. I'm building Node.js Lambda functions using node-lambda&nbsp...

2,007 views 1 5
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