sublime.plugin.zsh 635 Bytes
Newer Older
Dylan Hudson's avatar
Dylan Hudson committed
1
# Sublime Text 2 Aliases
2
#unamestr = 'uname'
3

4
5
local _sublime_darwin_subl=/Applications/Sublime\ Text\ 2.app/Contents/SharedSupport/bin/subl

6
if [[ $('uname') == 'Linux' ]]; then
7
	if [ -f '/usr/bin/sublime_text' ]; then
8
		st_run() { nohup /usr/bin/sublime_text $@ > /dev/null & }
9
	else
10
		st_run() { nohup /usr/bin/sublime-text $@ > /dev/null & }
11
	fi
12
alias st=st_run
13
elif  [[ $('uname') == 'Darwin' ]]; then
14
15
16
17
18
19
	# Check if Sublime is installed in user's home application directory
	if [[ -a $HOME/${_sublime_darwin_subl} ]]; then
		alias st='$HOME/${_sublime_darwin_subl}'
	else
		alias st='${_sublime_darwin_subl}'
	fi
20
fi
Dylan Hudson's avatar
Dylan Hudson committed
21
alias stt='st .'