Sublime Forum

`subl` command line tool always opens stable copy

#1

I have 2 copies of Sublime Text downloaded, stable and dev. As suggested by the docs, I have added the appropriate folder to my PATH:

export PATH="/Applications/Sublime Text.app/Contents/SharedSupport/bin:$PATH"

The two Sublime Text instances are:

/Applications/Sublime Text.app/
/Applications/Sublime Text-stable.app/

When I use subl . to open a folder, it always opens the folder in the stable channel binary, despite only the dev channel app being open.

I presume this is because the two apps are both claiming the com.sublimetext.4 bundle ID, and the dev channel app is losing because the stable channel loaded first for some reason. But I would expect to be able to control which copy of the app subl deals with by using the subl binary inside the appropriate app. (Or I guess by passing an argument to subl providing a particular ST app bundle, but there doesn’t seem to be an argument for that.)

Is there a recommended way to keep multiple copies of Sublime Text around? And should I file a bug about subl not using the right app, or is this actually behaving as expected?

0 Likes

#2

It’s not 100% clear to me from what you said above, so just to clarifyl even though you show only putting one of the app bundles in the path, you have tried executing the subl from each one specifically?

I have in the past run multiple versions of Sublime (though not literally simultaneously) on MacOS, but I don’t recall how much I may have used subl in that environment since I was mostly just testing that my packages work as expected.

0 Likes

#3

We’ve got a fix for this in the works.

0 Likes

#4

That’s great to hear! I started trying to pin down the behavior more exactly, but then it changed for some reason and I couldn’t immediately figure out what had happened. But if you guys know what’s up, that’s excellent. Thank you!

0 Likes