aboutsummaryrefslogtreecommitdiff
path: root/.mutt/keybindings
blob: 6c51e36e9ac081f30d8f7ea69c50e3bbb6ae808a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# vim: filetype=muttrc

bind pager j next-line
bind pager k previous-line
bind attach,index,pager \CD next-page
bind attach,index,pager \CU previous-page
bind pager gg top
bind pager G bottom
bind attach,index g noop
bind attach,index gg first-entry
bind attach,index G last-entry

bind index,pager \Cn sidebar-next
bind index,pager \Cp sidebar-prev

# ',l' performs a notmuch query, showing only the results
macro index ',l' "<enter-command>unset wait_key<enter><shell-escape>read -p 'notmuch query: ' x; echo \$x >~/.cache/mutt_terms<enter><limit>~i \"\`notmuch search --output=messages \$(cat ~/.cache/mutt_terms) | head -n 600 | perl -le '@a=<>;chomp@a;s/\^id:// for@a;s/\\+/\\\\+/g for@a;s/=/\\\\=/g for@a;$,=\"|\";print@a'\`\"<enter>" "show only messages matching a notmuch pattern"

macro index 'c' '<change-folder>?<change-dir><home>^K=<enter>'
macro index,pager 's' '<save-message>?'

macro attach 'V' "<pipe-entry>iconv -c --to-code=UTF8 > ~/.cache/mutt/mail.html<enter><shell-escape>$BROWSER ~/.cache/mutt/mail.html<enter>"
macro attach s <save-entry><kill-line>~/Downloads/