Out-of-the-box Command-line Tool Support for Windows

Jaakko Salonen 8 aastat tagasi uuendaja Artem Navrotsky 7 aastat tagasi 3
I am using command-line a lot in Windows (both command-prompt and PowerShell).

Right now, if want to use Sublime Text from command-line, I need to:
  • Add Sublime Text 2 folder to PATH
  • Use `sublime_text [whatever]`

I wish I could use `subl` instead of `sublime_text` just like in OS X.

Also I wish there was an option in Sublime Text setup (like checkbox) to automaticaly add Sublime Text 2 folder to PATH.

Can't you just create a subl.bat file somewhere on your path that launches sublime text and passes along all parameters? Easy peasy.
Hi! Yes I can create a .bat file or just use Set-Alias on PowerShell. My idea is that this feature should be supported out-of-the-box.

For this feature you need only add to registry key like this:

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\subl.exe]
@="C:\\Program Files\\Sublime Text 3\\sublime_text.exe"

After it you can run sublime editor with subl command.