11

I have installed Sublime Text 3 following the tutorial on unixmen.com. How to run it from terminal and how to check the version (from terminal or however)?

Muhamed Huseinbašić
  • 1,228
  • 3
  • 14
  • 19

3 Answers3

18

The command to start Sublime Text:

subl

The command to see its version:

subl --version
Radu Rădeanu
  • 166,822
  • 48
  • 327
  • 400
2

The usual command for Sublime Text is subl:

From subl --help:

$ subl --help
Sublime Text build 3065

Usage: sublime_text [arguments] [files]         edit the given files
   or: sublime_text [arguments] [directories]   open the given directories

Arguments:
  --project <project>: Load the given project
  --command <command>: Run the given command
  -n or --new-window:  Open a new window
  -a or --add:         Add folders to the current window
  -w or --wait:        Wait for the files to be closed before returning
  -b or --background:  Don't activate the application
  -h or --help:        Show help (this message) and exit
  -v or --version:     Show version and exit

Filenames may be given a :line or :line:column suffix to open at a specific
location.

Hence, to get the version:

$ subl -v
Sublime Text Build 3065

As Glutanimate noted, you can get the version from the Help menu, from About Sublime Text:

enter image description here

muru
  • 193,181
  • 53
  • 473
  • 722
  • 1
    You can also check the version via the UI: *Help* -> *About Sublime Text* – Glutanimate Sep 16 '14 at 17:08
  • 2
    @Glutanimate thanks. To discover that, I'd have to run it first. :D I'll update the answer. – muru Sep 16 '14 at 17:09
  • 1
    I saw `Build 3065` in the screenshot and cannot even figure out it is sublime 2 or sublime 3... – B.Mr.W. Jun 10 '15 at 21:30
  • 5
    @B.Mr.W. Same here. I'm guessing 3000–3999 represents version 3, but if so it would be nice to see that actually stated somewhere, especially since builds are usually given sequentially increasing system-generated numbers. – Marcelo Cantos Jun 28 '15 at 01:48
1

From the Sublime Text Unofficial Documentation:

You can create a symbolic lynk sudo ln -s /opt/Sublime\ Text\ 3/sublime_text /usr/bin/sublime. "/opt" being the dir where you installed Sublime.

The Documentation also shows how to add Sublime to the Unity Launcher if you wish.

Decio Lira
  • 7,716
  • 10
  • 39
  • 41