-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.neomuttrc
More file actions
105 lines (91 loc) · 3.68 KB
/
Copy path.neomuttrc
File metadata and controls
105 lines (91 loc) · 3.68 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
# ---------------------------------------------------------------------------
# Mail is synced locally by mbsync (~/.mbsyncrc) and indexed by notmuch
# (~/.notmuch-config); neomutt reads the local notmuch database. See bin/mail-sync.
#
# Identity, SMTP url, and nm_default_url (the machine-specific absolute DB path)
# live in ~/.neomutt/local.rc — generated by install.sh, gitignored, sourced
# via the platform rc below. The Fastmail password is resolved per-OS by
# bin/mail-pass (no GPG in the mail path).
# ---------------------------------------------------------------------------
# Platform-specific overrides + local identity
# (sets from / real_name / smtp_url / nm_default_url)
source `uname -s | grep -q Darwin && echo ~/.neomutt/macos.rc || echo ~/.neomutt/linux.rc`
# Sending (Fastmail SMTP; password resolved per-OS, no GPG)
set smtp_pass = "`$HOME/bin/mail-pass`"
set smtp_authenticators = "plain"
set ssl_starttls = yes
set ssl_force_tls = yes
set editor = "nvim"
# --- notmuch: local mail store with cross-folder threading ---
set virtual_spool_file = yes
set nm_query_type = "threads"
# nm_default_url is set in ~/.neomutt/local.rc (machine-specific absolute path)
virtual-mailboxes \
"Inbox" "notmuch://?query=folder:INBOX" \
"Unread" "notmuch://?query=tag:unread" \
"Flagged" "notmuch://?query=tag:flagged" \
"Sent" "notmuch://?query=folder:Sent" \
"Archive" "notmuch://?query=folder:Archive" \
"Drafts" "notmuch://?query=folder:Drafts"
# Save sent mail into the local Sent maildir so mbsync pushes it to Fastmail;
# it threads into notmuch on the next `notmuch new` (bin/mail-sync).
set record = "~/Mail/fastmail/Sent"
set copy = yes
# --- Performance (large local mailboxes) ---
# Cache parsed headers so re-opening a big vfolder doesn't re-read every file.
set header_cache = "~/.cache/neomutt"
# Trust the cache instead of stat-ing every message file to verify freshness.
set maildir_header_cache_verify = no
# Cap how many messages each notmuch query loads at startup. Loading every
# message (1000s) is what makes launch slow; notmuch itself is fast, so older
# mail stays instantly searchable via <change-vfolder> (X). Raise if needed.
set nm_db_limit = 500
# syntax highlighting
color body green default "^[+].*"
color body red default "^-.*"
color body cyan default "^@@.*"
color body brightyellow default "^diff.*"
color body brightyellow default "^index.*"
color body brightyellow default "^---.*"
color body brightyellow default "^[+][+][+].*"
color body magenta default "^commit [0-9a-f]+"
color body blue default "^(Author|Date):.*"
color body brightblue default "^Subject:.*"
color body brightcyan default "^[A-Za-z-]+-by:.*"
color body brightcyan default "^Cc:.*"
# Quoted replies
color quoted blue default
color quoted1 cyan default
color quoted2 green default
color quoted3 yellow default
color quoted4 magenta default
# Readability
set wrap = 0
set pager_stop = yes
set pager_index_lines = 10
set sort = threads
set sort_aux = last-date-received
set strict_threads = yes
set index_format = "%4C %Z %{%b %d} %-20.20L %s"
# Sidebar
set sidebar_visible = yes
set sidebar_width = 25
set sidebar_format = "%B%?F? [%F]?%* %?N?%N/?%S"
set sidebar_sort_method = unsorted
bind index,pager \Cj sidebar-next
bind index,pager \Ck sidebar-prev
bind index,pager \Co sidebar-open
bind index,pager B sidebar-toggle-visible
# Threading
folder-hook . 'push <collapse-all>'
bind index <return> collapse-thread
bind index za collapse-thread
bind index zA collapse-all
bind index l display-message
# Vim-like navigation
bind pager j next-line
bind pager k previous-line
bind pager g top
bind pager G bottom
# Switch notmuch vfolders
bind index,pager X change-vfolder