Parent directory

bbedit.plugin.zsh

420 bytes
 1alias bbpb='pbpaste | bbedit --clean --view-top'
 2
 3alias bbd=bbdiff
 4
 5#
 6# If the bb command is called without an argument, launch BBEdit
 7# If bb is passed a directory, cd to it and open it in BBEdit
 8# If bb is passed a file, open it in BBEdit
 9#
10function bb() {
11    if [[ -z "$1" ]]
12    then
13        bbedit --launch
14    else
15        bbedit "$1"
16        if [[ -d "$1" ]]
17        then
18            cd "$1"
19        fi
20    fi
21}