Remote Access With Sublime Text 3

I want to use Sublime Text 3 directly with my external servers so that I can avoid needing to upload changed files from my desktop using another FTP program. I also want to be able to launch it from the command line.

My first approach was to install ST3 directly on one my servers (T60). While this made it available on the server, it also meant that I needed to be on the server in order to access the app.

I started out at . First, I made sure I was logged in to the server as myself (not as root) and then made sure I was in my home directory. Then I ran the following command to complete the install:

cd && wget && sudo dpkg -i sublime-text_build-3103_i386.deb

Next, I needed to make it possible to launch the app from the command line. I went here to find more. I ran this command to to enable this capability:

sudo ln -s /opt/sublime_text/sublime_text /usr/local/bin/subl

Now all I need to do to launch ST3 from the command line is run:


This works beautifully, so long as I’m working directly on the server.

I needed another approach for tunneling in remotely from my desktop machine. The simplest solution was to add the Sublime SFTP package ( to my desktop install.

Once added, I followed the instructions in the package description file to set up the config files. There’s a bit more on using public/private key authorization here at and at .

Works like a charm now!

Well, almost… When I tried to upload changes to the Cake project via Sublime SFTP, I ran into a permissions error since I was not logged in as root. When installed, Cake sets the default owner & group to root:root.

When I did a chown on the app to set a new owner and group, I caused a bit of havoc. It turns out, after doing the chown, I then needed to run the following commands to update permissions on the tmp and log folders and files:

HTTPDUSER=`ps aux | grep -E '[a]pache|[h]ttpd|[_]www|[w]ww-data|[n]ginx' | grep -v root | head -1 | cut -d\  -f1`
setfacl -R -m u:${HTTPDUSER}:rwx tmp
setfacl -R -d -m u:${HTTPDUSER}:rwx tmp
setfacl -R -m u:${HTTPDUSER}:rwx logs
setfacl -R -d -m u:${HTTPDUSER}:rwx logs

All good again:-)