Skip to content

Instantly share code, notes, and snippets.

@alexanderjsingleton
Last active December 4, 2016 18:59
Show Gist options
  • Save alexanderjsingleton/9feea2b114e14891f5d666c60decb925 to your computer and use it in GitHub Desktop.
Save alexanderjsingleton/9feea2b114e14891f5d666c60decb925 to your computer and use it in GitHub Desktop.
How to create Sublime short-cut in terminal via bash-profile in Mac OS X Sierra.

Sublime Text Shortcut Guide

  1. Open Mac Terminal
  2. Go to homebrew.sh; copy and enter the following: /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
  3. Enter brew install wget
  4. Enter the following into your Mac Terminal: open ~/.bash_profile but if for whatever reason you don't have one configured, enter sudo nano .bash_profile.
  5. To become sufficiently Rubified: brew install ruby
  6. Download Sublime Text 3 then go to root/usr (e.g. cd alexanderjsingleton/).
  7. Next after you've installed Sublime 3, open /Applications/Sublime\ Text.app/Contents/SharedSupport/bin/subl
  8. Create a symlink called sublime by entering ln -s "/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl" /usr/local/bin/sublime
  9. Enter the following into your Mac Terminal: open ~/.bash_profile but if for whatever reason you don't have one configured, enter sudo nano .bash_profile.
  10. Exit and open your bash profile; the following example should be contained in the profile export PATH=/usr/local/bin:$PATH
  11. Test by entering the directory of app-files (e.g. sublime .).
  12. Boom! A special thanks to the great Ashley Nolan's blog, though for whatever reason my new MacBookPro couldn't access the bash-profile, so I had to create one, which is why I included that caveat in step 4. I trust this will assuage any systemAdmin anguish fellow developers may take for granted. :D
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment