diff options
author | Óscar Nájera <hi@oscarnajera.com> | 2021-01-04 13:37:38 +0100 |
---|---|---|
committer | Óscar Nájera <hi@oscarnajera.com> | 2021-01-04 13:37:38 +0100 |
commit | 3a8b6767b1ae97d4486ed6efd6f8cdc302ccf083 (patch) | |
tree | 59af68e1d59ae4b0459ef6a566911991ee1436df | |
parent | 3d050958744b4bb27000362e6c6c43fe6d6dbb91 (diff) | |
download | dotfiles-3a8b6767b1ae97d4486ed6efd6f8cdc302ccf083.tar.gz dotfiles-3a8b6767b1ae97d4486ed6efd6f8cdc302ccf083.tar.bz2 dotfiles-3a8b6767b1ae97d4486ed6efd6f8cdc302ccf083.zip |
simplify sent search
-rwxr-xr-x | bin/tagmail | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/bin/tagmail b/bin/tagmail index 9ca1771..f7836b1 100755 --- a/bin/tagmail +++ b/bin/tagmail @@ -182,14 +182,9 @@ (display (colorize-string "[Inbox]\n" 'BOLD 'YELLOW)) (let* ((my-emails (list "hi@oscarnajera.com" "hello@oscarnajera.com" "najera.oscar@gmail.com" "on@mathias-kettner.de" "oscar.najera@tribe29.com")) - (sent (format #f "~?" "(~A) AND NOT (~A)" - (map (lambda (header) - (string-join - (map (lambda (address) - (format #f "~a:~a" header address)) - my-emails) - " OR ")) - (list "from" "to"))))) + (sent (format #f "(~A) AND NOT (~A)" + (format #f "~{from:~a~^ OR ~}" my-emails) + (format #f "~{to:~a~^ OR ~}" my-emails)))) (notmuch-tag options ffi-db `(("+sent" ,sent "Emails I have sent") ("+inbox" "*" "Inbox for the rest")) #t))) |