Source

dotfiles / bin / bb

#!/usr/bin/env zsh

# Information for this script comes from:
# <http://superuser.com/questions/383124/knowing-user-is-sshing-in-from-a-shell-script>

if [[ -n $SSH_CONNECTION ]]
then
  vim "$@"
else
  bbedit -w  "$@"
fi