Sublime Text 3 and Terminal prompt for OS X Mavericks?

前端 未结 7 1050
半阙折子戏
半阙折子戏 2020-12-22 23:18

I\'m trying to set-up Sublime Text 3 on OS X Mavericks and getting levels of frustration.

I\'ve followed all of the usual suspects in regards to installation and se

7条回答
  •  北海茫月
    2020-12-22 23:36

    Rather than having cumbersome sudo links to setup I prefer to use a simple bash function and use the native Mac open command:

    #somewhere in your .bashrc or .zshrc
    sublime () {
        open -a "Sublime Text" $@
    }
    

    Now all you have to do is sublime . whenever you want to open up sublime from a given folder. Obviously you can simply rename it subl.

    Note The name to write in the -a parameter is the name of the application as stored in the the /Applications folder:

    enter image description here

提交回复
热议问题