Sublime Forum

Sublime Text 2 - OS X Command Line problems

#1

I’m going through some Ruby tutorials and trying to get Sublime Text 2 setup in the command line in OSX. I have made

mkdir ~/bin
and then typed in my command line

ln -s “/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl” ~/bin/subl
and then entered

export PATH="$PATH:~/bin"
Also, in SB2, I saved

.bash_profile
in ~/bin

So when I type

subl --help
I get

-bash: subl: command not found

I’ve been stuck on this since yesterday and need help. I checked some similar threads and ran through those directions but I’m stumped and feeling noobish than ever. Any help is appreciated. Thanks.

PS. I’m using Mavericks.

0 Likes

#2

I don’t have ST2 any more so can’t verify the soft link. But check the file system location of .bash_profile; that should be in ~ (your home) rather than ~/bin. Then, close and reopen your terminal to pick up the change. You might consider putting the export in ~/.bashrc instead but think both will work.

0 Likes

#3

[quote=“fburleigh”]

I don’t have ST2 any more so can’t verify the soft link. But check the file system location of .bash_profile; that should be in ~ (your home) rather than ~/bin. Then, close and reopen your terminal to pick up the change. You might consider putting the export in ~/.bashrc instead but think both will work.[/quote]

Thanks for the reply. I put the bash_profile in the ~ folder. I’m still getting

yaw-MacBook-Pro:bin way$ subl --help
-bash: subl: command not found
yaw-MacBook-Pro:bin way$

lol I’m losing my mind over this.

0 Likes

#4

figured it out https://gist.github.com/olivierlacan/1195304

0 Likes