From: martin f. krafft Date: Fri, 9 May 2008 13:27:10 +0000 (+0100) Subject: properly handle absent aliases files X-Git-Url: https://git.madduck.net/etc/mutt.git/commitdiff_plain/5089b3ee80379f6a88a14fb4c091d02c244a9cbd?ds=inline;hp=a3a2e59a9cb6ad1bf4b2397d91cfebd7b00a0c31 properly handle absent aliases files --- diff --git a/.mutt/muttrc b/.mutt/muttrc index 35915bc..84260b1 100644 --- a/.mutt/muttrc +++ b/.mutt/muttrc @@ -4444,7 +4444,5 @@ source $my_confdir/hooks set my_mailboxes = `ls ~/.var/offlineimap/mailboxes 2>/dev/null || echo /dev/null` source $my_mailboxes -# this sucks a bit since we hardcode ~/.mutt instead of using $my_confdir, but -# apparently we can't expand that mutt variable for the subshell... -set alias_file = `ls ~/.mutt/aliases 2>/dev/null || echo /dev/null` -source $alias_file +set alias_file="$my_confdir/aliases" +source "test -f $alias_file && cat $alias_file || echo unset alias_file|"