X-Git-Url: http://id.pley.net/dotfiles.git/blobdiff_plain/a12d8dfd6fd9b49029de9dc9d67cb05749b51901..5a2aa4d6a19afcbc19ced19b67d2ad4f99b9de5a:/zsh_webkit_login diff --git a/zsh_webkit_login b/zsh_webkit_login index 6dc4657..589a236 100644 --- a/zsh_webkit_login +++ b/zsh_webkit_login @@ -20,4 +20,22 @@ _switchto() { _arguments '1:dir:_webkit_dirs' } compdef _switchto switchto +if [[ $( has bbedit ) == 'yes' ]]; then + export GUI_EDITOR="bbedit -w" +elif [[ $( has mate_wait ) == 'yes' ]]; then + export GUI_EDITOR="mate_wait" +else + export GUI_EDITOR="vim" +fi + +if [[ -z "$SSH_TTY" ]]; then + export EDITOR="$GUI_EDITOR" + export SVN_LOG_EDITOR="$GUI_EDITOR" + export GIT_SEQUENCE_EDITOR="$GUI_EDITOR" +else + export EDITOR=vim + export SVN_LOG_EDITOR=vim + export GIT_SEQUENCE_EDITOR=vim +fi + switchto git