if [[ $KONSOLE_PROFILE_NAME ]]; then
TERM=xterm-256color
- fi
+ fi
# todo: not sure this works in sakura
#stty werase undef
}
- o() {
- if type gvfs-open &> /dev/null ; then
- gvfs-open "$@"
- else
- xdg-open "$@"
- fi
- # another alternative is run-mailcap
- }
+o() {
+ if type gvfs-open &> /dev/null ; then
+ gvfs-open "$@"
+ else
+ xdg-open "$@"
+ fi
+ # another alternative is run-mailcap
+}
ipdrop() {
s iptables -A INPUT -s $1 -j DROP
if [[ -e /nocow/btrfs-stale ]] && ((`command ls -AUq /nocow/btrfs-stale|wc -l`)); then
ps_char="! $ps_char"
fi
+ if test -e /Maildir/new/*; then
+ ps_char='!BOUNCE! '"$ps_char"
+ fi
if [[ -e /nocow/mailtest-failure ]]; then
- ps_char="@#$@#$ $ps_char"
+ ps_char='@#$@#$ '"$ps_char"
fi
source /a/bin/bash_unpublished/source-state
if [[ ! $SSH_CLIENT && $MAIL_HOST != $HOSTNAME ]]; then
cat >>/etc/exim4/update-exim4.conf.conf <<EOF
dc_eximconfig_configtype='satellite'
dc_smarthost='$smarthost'
-# i dunno if this would ever get used.
+# The manpage incorrectly states this will do header rewriting, but
+# that only happens if we have dc_hide_mailname is set.
+dc_readhost='iankelling.org'
+# Only used in case of bounces.
dc_localdelivery='maildir_home'
EOF
fi
# local mail that bounces to alerts goes to /Maildir
-mkdir -p /Maildir{cur,tmp,new}
-chgrp Debian-exim /Maildir{cur,tmp,new}
-chmod 775 /Maildir{cur,tmp,new}
-if id -g 1000 &>/dev/null; then
- usermod -a -G Debian-exim 1000
-fi
-if [[ -e /m/md ]]; then
- ln -s /Maildir /m/md/bounces
+dirs=(/Maildir/{cur,tmp,new})
+mkdir -p ${dirs[@]}
+chown -R $u:Debian-exim /Maildir
+chmod 775 ${dirs[@]}
+usermod -a -G Debian-exim $u
+if [[ -d /m/md ]]; then
+ sudo -u $u ln -sf -T /Maildir /m/md/bounces
fi
# put spool dir in directory that spans multiple distros.