Fixing Sublime Text 2 and GoSublime

I’m still using Sublime Text 2 because it works well for me. I also use the GoSublime plugin to trigger go fmt and goimports on every save. This broke when GoSublime updated recently.

ETA: As of 2016/05/18 this broke again, still working out why.

** ETA2: I never got Sublime Text 2 to work properly with GoSublime. However, upgrading to Sublime Text 3 was painless and GoSublime works properly again!**

The fix: Instead of using the Package Manager, manually clone down the git repo and check out and older version (hat tip these folks).

Step 1: Uninstall GoSublime through the Package Manager.

Step 2: Rename or delete the GoSublime folder in /Users/<USERNAME>/Library/Application\ Support/Sublime\ Text\ 2/Packages.

Step 3: Pull down the GoSublime repo.

Step 4: Check out commit 852a15fb933

Sublime text 2 keyboard shortcuts – delete an entire line

I’ve learned some new shortcuts for Sublime Text 2. I’ve been learning a few vim shortcuts, and I wanted to figure out how to do some of the things I can do in vim in Sublime.

  1. Ctrl + shift + k
    Deletes entire line. Ctrl is the correct key, even for OSX.

  2. Cmd + x
    Cuts the line if you want to move it somewhere. This does not require highlighting anything.

And as a note, many of the usual keyboard shortcuts work this way. Cmd + c will copy the line without needing to select anything.