Skip to content

Instantly share code, notes, and snippets.

@n0nick
Forked from joefiorini/.vmail.sh
Created April 16, 2012 10:36
Show Gist options
  • Save n0nick/2397607 to your computer and use it in GitHub Desktop.
Save n0nick/2397607 to your computer and use it in GitHub Desktop.
Shell function to support multiple accounts for vmail (http://danielchoi.com/software/vmail.html) using one command.
mail() {
ACCT="$1"
shift
if [[ $ACCT = "p" ]]; then
sh -c cd ~/.vmail ; vmail -c ~/.vmailrc-p "$@"
elif [[ $ACCT = "w" ]]; then
sh -c cd ~/.vmail ; vmail -c ~/.vmailrc-w "$@"
else
echo "Please specify an account."
fi
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment