However, we still need to give this new script permission to be executed. You have make a new script called sublime on the executable path. The $* ensures that any parameters such as file names you pass to the script are passed on to the sublime start-up script. Create a new file by launching an editor, use gksudo if you are launching a graphical editor as the file will be created in the protected part of the file system: gksudo gedit /usr/local/bin/sublimeĪdd the following script to this file that will change to the folder where the sublime binaries live and then run its usual starup script. Rather than add the sublime folder to the path and making it messy, I create a little bash script that simply calls sublime. Add Sublime Text to path to run it from anywhere If you do upgrade the version of Sublime, simply download the new version and extract it into the /opt/sublime folder, then just delete the symbolic link and create a new one to point to the new folder. ln -s /opt/sublime/Sublime\ Text\ 2 /opt/sublime/current Move the folder and all its contents extracted from the sublime text archive file: sudo mv ~/Downloads/Sublime\ Text\ 2 /opt/sublimeĬreate a symbolic link called current that points to the folder you have just moved. I am assuming that we will download new versions occasionally and have other apps installed in /opt. You just create an apps folder in your own home directory if you use only one login account with Ubuntu.Ĭreate a folder to contain the Sublime Text app using the following command in a terminal: sudo mkdir /opt/sublime I usually place 3rd party software in the folder /opt although you could use /usr/local. You can also double clicking and selecting the Extract button when the archive manager app opens or use the following command in a terminal: tar jvxf “Sublime Text 2.0.2 圆4.tar.bz2” Install Sublime Text in /opt You can extract the whole archive by right-clicking on the file in the file browser (nautilus) and selecting Extract here The download will be an archive file like zip but using the Unix commands tar and bzip2. Download the latest version from the Sublime Text front page (it should give you a button specific to the OS you are currently using, i.e. Download Sublime TextĪs Sublime is not part of the Ubuntu package management system (apt-get), it requires a manual download and install. Sublime Text is a really popular text editor will great language support and a lot of plugin features that are geared towards software developers.Īlthough I’m usually in Emacs, lots of people have asked me how best to set Sublime Text on Ubuntu, so here is my prefered method.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |