Plugin for Sublime Text, a cross platform text and code editor, available for Linux, Mac OS X, and Windows.
- Clone this repository somewhere on your machine. This guide will assume
~/.zsh/sublime.
git clone https://github.com/valentinocossar/sublime.git ~/.zsh/sublime- Add the following to your
.zshrc:
source ~/.zsh/sublime/sublime.plugin.zsh- Start a new terminal session.
- Clone this repository into
$ZSH_CUSTOM/plugins(by default~/.oh-my-zsh/custom/plugins)
git clone https://github.com/valentinocossar/sublime.git $ZSH_CUSTOM/plugins/sublime- Add the plugin to the list of plugins for Oh My Zsh to load:
plugins=(sublime)- Start a new terminal session.
-
If
stcommand is called without an argument, launch Sublime Text. -
If
stis passed a directory,cdto it and open it in Sublime Text (in the current window, if there is one open, it is equivalent tosubl -a). -
If
stis passed a file, open it in Sublime Text (in the current window, if there is one open, it is equivalent tosubl -a). -
If
sttcommand is called, opening the current folder in Sublime Text (in the current window, if there is one open, it is equivalent tosubl -a .orst .). -
If
sstcommand is called, it is likesudo st, opening the file or folder in Sublime Text (in the current window, if there is one open, it is equivalent tosudo subl -a). Useful for editing system protected files. -
If
stpcommand is called, it find a.sublime-projectfile by traversing up the directory structure. If there is no.sublime-projectfile, but if the current folder is a Git repo, opens up the root directory of the repo. If the current folder is not a Git repo, then opens up the current directory (in the current window, if there is one open).