Sublime Text Editor is one of the best cross-platform editor out there for editing source code. It is capable of syntax highlighting for wide range of file extensions like Python, C, C++, Java, HTML, JS, PHP, LaTeX & even Arduino. Sublime Text Editor is not opensource & not an free editor, but in last update the expiry date has been removed by the developers, so you can use Sublime text as there is no enforce time limit for evaluation.
Sublime Text Editor can be installed manually following the steps below :
- Download correct bit version of Sublime Text 2 from Official Website.
- Now, extract the downloaded Sublime text 2 .tar.bz2 in /home directory by simply right clicking on it.
- Now move the extracted folder 'Sublime Text 2' to the proper location. Open Terminal/Konsole and type :
sudo mv Sublime Text 2 /opt/
The extracted folder will be moved in /opt directory of your system.
- Now, we have to add following command for symbolic link. Open terminal & type :
sudo ln -s /opt/Sublime Text 2/sublime_text /usr/bin/sublime
- Now, to add application icon in launcher. In terminal type :
sudo gedit /usr/share/applications/sublime.desktop
(Replace gedit by any other editor like kate, vim or even sublime) and copy the following lines into it & hit on 'Save' button.
[Desktop Entry]
Version=2.0
Name=Sublime Text 2
# Only KDE 4 seems to use GenericName, so we reuse the KDE strings.
# From Ubuntu's language-pack-kde-XX-base packages, version 9.04-20090413.
GenericName=Text Editor
Exec=sublime
Terminal=false
Icon=/opt/Sublime Text 2/Icon/48x48/sublime_text.png
Type=Application
Categories=TextEditor;IDE;Development
X-Ayatana-Desktop-Shortcuts=NewWindow
[NewWindow Shortcut Group]
Name=New Window
Exec=sublime -n
TargetEnvironment=Unity
Login & out & you'll notice launcher icon of sublime text in Menu.
I have tested same .desktop configuration in openSUSE Gnome & it shows up in launcher too, so no need to modify if you're using other desktop environment. Didn't tested in KDE though.
Happy coding.