From 3c0a801804d138c51f215cf49b98ed6fa5a2dacd Mon Sep 17 00:00:00 2001 From: Jan Pokorný Date: Fri, 17 May 2013 14:43:48 +0200 Subject: Mutt config: maildir_watch_setup: add support for blacklist MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Jan Pokorný --- .mutt/maildir_watch_setup.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to '.mutt') diff --git a/.mutt/maildir_watch_setup.sh b/.mutt/maildir_watch_setup.sh index 53d9bb4..03a0b63 100755 --- a/.mutt/maildir_watch_setup.sh +++ b/.mutt/maildir_watch_setup.sh @@ -4,13 +4,15 @@ # the script suppose ./folders file with one folder per-line, # prefixed with '=' and ending with '\' +: ${BLACKLIST:="__DUMMY__"} + wget https://raw.github.com/erikw/dotfiles/personal/bin/maildir_watch.sh -O- \ | sed \ -e "s|\(maildir_path=\"\)[^\"]*\"|\1$( grep -E 'set folder\s+=' ../.muttrc | tr -d ' ' | cut -d= -f2 | sed 's|\~|$HOME|' )\"|" \ -e "s|\(mailboxes=(\)[^)]*)|\1$( - grep -E '=[A-Za-z0-9.-]+\s.*\\' folders \ + grep -E '=[A-Za-z0-9.-]+\s.*\\' folders | grep -Ev "${BLACKLIST}" \ | sed 's|^=\([A-Za-z0-9.-]\+\)\s.*$|\1|' | paste -s ))|" > maildir_watch.sh chmod +x maildir_watch.sh -- cgit