diff options
author | Yaroslav Chvanov <yaroslav.chvanov@gmail.com> | 2024-08-14 18:54:04 +0300 |
---|---|---|
committer | Yaroslav Chvanov <yaroslav.chvanov@gmail.com> | 2024-08-14 19:02:38 +0300 |
commit | 86a1f1d66fb463a8745c3957d8a47037ac9e6ff6 (patch) | |
tree | abc0ac09afbf1b17c5489506a700681936153b5f | |
parent | 0d9d2fea326abe821a6e64630f332f1933478470 (diff) |
muttrc: use XDG_CACHE_HOME in notmuch integration
Fixes `sh: 1: cannot create /home/<username>/.cache/mutt_terms:
Directory nonexistent`.
-rw-r--r-- | share/mutt-wizard.muttrc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/share/mutt-wizard.muttrc b/share/mutt-wizard.muttrc index 27ae216..f236bc4 100644 --- a/share/mutt-wizard.muttrc +++ b/share/mutt-wizard.muttrc @@ -101,7 +101,7 @@ macro index \eh "<pipe-message>$prefix/libexec/gpg-wks-client --receive | msmtp macro index,pager a "<enter-command>set my_pipe_decode=\$pipe_decode pipe_decode<return><pipe-message>abook --add-email<return><enter-command>set pipe_decode=\$my_pipe_decode; unset my_pipe_decode<return>" "add the sender address to abook" macro index \Cr "T~U<enter><tag-prefix><clear-flag>N<untag-pattern>.<enter>" "mark all messages as read" macro index O "<shell-escape>mailsync<enter>" "run mailsync to sync all mail" -macro index \Cf "<enter-command>unset wait_key<enter><shell-escape>printf 'Enter a search term to find with notmuch: '; read x; echo \$x >~/.cache/mutt_terms<enter><limit>~i \"\`notmuch search --output=messages \$(cat ~/.cache/mutt_terms) | head -n 600 | perl -le '@a=<>;s/\^id:// for@a;$,=\"|\";print@a' | perl -le '@a=<>; chomp@a; s/\\+/\\\\+/g for@a; s/\\$/\\\\\\$/g for@a;print@a' \`\"<enter>" "show only messages matching a notmuch pattern" +macro index \Cf "<enter-command>unset wait_key<enter><shell-escape>printf 'Enter a search term to find with notmuch: '; read x; echo \$x >\"\${XDG_CACHE_HOME:-\$HOME/.cache}/mutt_terms\"<enter><limit>~i \"\`notmuch search --output=messages \$(cat \"\${XDG_CACHE_HOME:-\$HOME/.cache}/mutt_terms\") | head -n 600 | perl -le '@a=<>;s/\^id:// for@a;$,=\"|\";print@a' | perl -le '@a=<>; chomp@a; s/\\+/\\\\+/g for@a; s/\\$/\\\\\\$/g for@a;print@a' \`\"<enter>" "show only messages matching a notmuch pattern" macro index A "<limit>all\n" "show all messages (undo limit)" # Sidebar mappings |