This isn't something you can do, an application has to register itself to handle custom URL schemes like this.
It appears Gitbox must have registered itself for the github-mac:// URL form. I'm not sure if that's considered good practice or not to basically take over someone else's URL handler, given that people might reasonably assume that that button is supposed to open the GitHub for Mac client. I could happily make SourceTree handle this URL form too, but I think the user should have control over which application this goes to if they have more than one installed, and I'm not sure how they do that easily. It appears that http://www.rubicode.com/Software/RCDefaultApp/ is one way to handle it, but it would be nicer if there was a way that didn't require extra software.
Thanks Steve. I did end up downloading the Rubicode software and it does what it says on the tin. I agree it seems something that should be handled at the OS level though.
Now that said, now that I've associated SourceTree to he URL handler the application itself doesn't take the parameter (aka, the repository I'm interested in cloning). Admittedly I don't NEED this functionality but I'm aflicted with an extremely enflamed case of laziness and would like to sooth the rash with a single click appaoch. Interestingly, neither did GitHub (although it was quite happy to beg for the right to have the association).
Anyway, is this something reasonable to add to add to the roadmap? Is there a way to "hack it" into working? Is it a dream worth giving up on?
Yeah, a little bit of code is needed on the SourceTree end to make this work. Supporting it is actually trivial, I could probably bash the code out in about 15 minutes - my main concern is whether it would annoy people to take this over. It's not something that's particularly easy to turn on/off dynamically inside SourceTree once it's in (it's advertised in the app's Info.plist), it really does have to be done by the user via that RCDefaultApp.
I'd quite like some other views on this - feel free to raise it as a feature request at https://jira.atlassian.com and encourage anyone else who might be interested in it to comment / vote. If it seems like it will be welcome rather than annoying, I'm happy to add it.
It's a bit difficult to re-instate the GitHub client's own URL hook if we overwrite it in Windows, that's why I haven't implemented an option to allow github-windows: URLs to be handled by SourceTree yet (it's toggleable on Mac because restoring the settings is easy). That said, I'm not sure if their own client would restore them if it found they were pointing somewhere else. I've logged this here: https://jira.atlassian.com/browse/SRCTREEWIN-449
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...
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!
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