diff options
author | Hsieh Chin Fan <typebrook@gmail.com> | 2022-04-05 15:00:11 +0800 |
---|---|---|
committer | Hsieh Chin Fan <typebrook@gmail.com> | 2022-04-05 15:00:11 +0800 |
commit | dcd2c83a44b9372f8602a57a34e2c9066abd1ec5 (patch) | |
tree | b0222a8191405b531c8d589a4e72d447f190923c /mutt | |
parent | 2b4bc30472064b0181fb56b63eb3dab3a1c8d19a (diff) |
update
Diffstat (limited to 'mutt')
-rw-r--r-- | mutt/mailcap | 2 | ||||
-rw-r--r-- | mutt/muttrc | 163 |
2 files changed, 165 insertions, 0 deletions
diff --git a/mutt/mailcap b/mutt/mailcap new file mode 100644 index 0000000..b3ae9f4 --- /dev/null +++ b/mutt/mailcap | |||
@@ -0,0 +1,2 @@ | |||
1 | text/html; xdg-open '%s' &; test=test -n "$DISPLAY"; needsterminal; | ||
2 | text/html; lynx -dump %s; nametemplate=%s.html; copiousoutput; | ||
diff --git a/mutt/muttrc b/mutt/muttrc new file mode 100644 index 0000000..deeee67 --- /dev/null +++ b/mutt/muttrc | |||
@@ -0,0 +1,163 @@ | |||
1 | # IMAP/SMTP settings | ||
2 | set folder = "imaps://pham@mail.topo.tw:993/" | ||
3 | set imap_pass = `pass pham@topo.tw` | ||
4 | set header_cache = "~/.cache/mutt" | ||
5 | set message_cachedir = "~/.cache/mutt" | ||
6 | set smtp_url = "smtp://pham@mail.topo.tw:25" | ||
7 | set smtp_pass = "$imap_pass" | ||
8 | |||
9 | # Identify meself | ||
10 | set from = "pham@topo.tw" | ||
11 | set realname = "謝晉凡 Hsieh Chin Fan" | ||
12 | set signature="$SETTING_DIR/.signature" | ||
13 | set pgp_use_gpg_agent=yes | ||
14 | set crypt_use_gpgme=yes | ||
15 | set pgp_timeout=300 | ||
16 | set pgp_sign_as=6DD8C14A # replace 6DD8C14A with your gpg key id | ||
17 | |||
18 | # Basic Mailbox | ||
19 | set spoolfile = "+INBOX" | ||
20 | set mbox= "+mbox" | ||
21 | set move = yes | ||
22 | set record = "+Sent" | ||
23 | set trash = "+Trash" | ||
24 | set postponed = "+Drafts" | ||
25 | |||
26 | subscribe talk-tw@openstreetmap.org | ||
27 | |||
28 | # Interface | ||
29 | set editor = "vim" | ||
30 | set charset = "utf-8" | ||
31 | set send_charset = "us-ascii:utf-8" | ||
32 | set header = no | ||
33 | set pager_stop | ||
34 | set sleep_time = 0 # When changing folder | ||
35 | set timeout = 10 | ||
36 | set quit = ask-no | ||
37 | set sort = threads | ||
38 | set pager_index_lines = 5 | ||
39 | set markers = no # Remove '+' for long links with limited terminal width | ||
40 | set index_format = "%4C %8Y %Z %(%b %d) %-15.15L (%?l?%4l&%4c?) %s" | ||
41 | |||
42 | # Vim-style key binding, \c means Ctrl | ||
43 | # ref: https://fancyseeker.github.io/2015/08/19/mutt/#vim%E9%A3%8E%E6%A0%BC%E9%94%AE%E4%BD%8D%E7%BB%91%E5%AE%9A | ||
44 | bind index <Return> sync-mailbox | ||
45 | bind index q browse-mailboxes | ||
46 | bind index y edit-label | ||
47 | bind index x tag-entry | ||
48 | bind index t edit-label | ||
49 | bind index \cl limit | ||
50 | bind index \cj next-entry | ||
51 | bind index \ck previous-entry | ||
52 | bind index,browser G last-entry | ||
53 | bind index,browser g noop | ||
54 | bind index,browser gg first-entry | ||
55 | bind index \cf next-page | ||
56 | bind index \cb previous-page | ||
57 | bind index \cd half-down | ||
58 | bind index \cu half-up | ||
59 | bind index } bottom-page | ||
60 | bind pager G bottom | ||
61 | bind pager g noop | ||
62 | bind pager gg top | ||
63 | bind pager j next-line | ||
64 | bind pager k previous-line | ||
65 | bind pager \cf next-page | ||
66 | bind pager \cb previous-page | ||
67 | bind pager \cd half-down | ||
68 | bind pager \cu half-up | ||
69 | bind pager \cj next-entry | ||
70 | bind pager \ck previous-entry | ||
71 | bind attach x view-mailcap | ||
72 | macro generic,index,pager \cr ":source ~/.config/mutt/muttrc\n" "Reload mutt's configuration file" | ||
73 | macro index <Return> ":exec sync-mailbox\n" "Sync Mailbox" | ||
74 | macro index *a "Tall\n" "Select All" | ||
75 | macro index *n "\ctall\n" "Deselect All" | ||
76 | |||
77 | # Sidebar | ||
78 | mailboxes =INBOX =mbox "+---------- Watch ----------" =pay =osm =keep "+-------- Processed --------" =Sent =Trash =Drafts | ||
79 | set mail_check = 120 | ||
80 | set mail_check_stats | ||
81 | set imap_check_subscribed | ||
82 | set sidebar_visible = yes | ||
83 | set sidebar_format = '%B%?F? [%F]?%* %?N?%N/?%S' | ||
84 | set sidebar_short_path = yes | ||
85 | bind index,pager B sidebar-toggle-visible | ||
86 | bind index,pager \Cp sidebar-prev | ||
87 | bind index,pager \Cn sidebar-next | ||
88 | bind index,pager \Co sidebar-open | ||
89 | bind index,pager <F5> sidebar-prev-new | ||
90 | bind index,pager <F6> sidebar-next-new | ||
91 | color indicator cyan black | ||
92 | color sidebar_highlight white color8 | ||
93 | color sidebar_divider color8 black | ||
94 | color sidebar_flagged red black | ||
95 | color sidebar_new green black | ||
96 | |||
97 | # basic colors | ||
98 | color normal white black | ||
99 | color error red black | ||
100 | color tilde white black | ||
101 | color message cyan black | ||
102 | color markers red black | ||
103 | color attachment brightred black | ||
104 | color search brightmagenta black | ||
105 | color status brightwhite black | ||
106 | color indicator white blue | ||
107 | color tree magenta black # arrows in threads | ||
108 | |||
109 | # For list | ||
110 | # Highlight mails by their status. For a specific pattern(e.g. ~N), pleas read mutt manual 4.2 | ||
111 | color index red black "~A" # all messages | ||
112 | color index brightred black "~E" # expired messages | ||
113 | color index brightcyan black "~N" # new messages | ||
114 | color index brightcyan black "~O" # old messages | ||
115 | color index brightmagenta black "~Q" # messages that have been replied to | ||
116 | color index white black "~R" # read messages | ||
117 | color index brightblue black "~U" # unread messages | ||
118 | color index brightblue black "~U~$" # unread, unreferenced messages | ||
119 | color index brightblue black "~v" # messages part of a collapsed thread | ||
120 | color index brightblue black "~P" # messages from me | ||
121 | color index cyan black "~p!~F" # messages to me | ||
122 | color index brightgreen black "~N~p!~F" # new messages to me | ||
123 | color index brightgreen black "~U~p!~F" # unread messages to me | ||
124 | color index green black "~R~p!~F" # messages to me | ||
125 | color index red black "~F" # flagged messages | ||
126 | color index red black "~F~p" # flagged messages to me | ||
127 | color index red black "~N~F" # new flagged messages | ||
128 | color index red black "~N~F~p" # new flagged messages to me | ||
129 | color index red black "~U~F~p" # new flagged messages to me | ||
130 | color index brightgreen black "~T" # tagged messages | ||
131 | color index black brightmagenta "~D" # deleted messages | ||
132 | color index white black "~v~(!~N!~O)" # collapsed thread with no unread | ||
133 | color index magenta black "~v~(~N|~O)" # collapsed thread with some unread | ||
134 | color index magenta black "~N~v~(~N)" # collapsed thread with unread parent | ||
135 | color index red white "~v~(~F)!~N" # collapsed thread with flagged, no unread | ||
136 | color index yellow white "~v~(~F~N)" # collapsed thread with some unread & flagged | ||
137 | color index green white "~N~v~(~F~N)" # collapsed thread with unread parent & flagged | ||
138 | color index green white "~N~v~(~F)" # collapsed thread with unread parent, no unread inside, but some flagged | ||
139 | color index yellow red "~v~(~D)" # thread with deleted (doesn't differentiate between all or partial) | ||
140 | |||
141 | # color header | ||
142 | color header green black "^(From)" | ||
143 | color header brightyellow black "^(Subject)" | ||
144 | |||
145 | # Set quote's starting symbol | ||
146 | set quote_regexp = "^([ ]t]*[|>:}#])+" | ||
147 | set quote_regexp = "^([ \t ]*[>])+" | ||
148 | |||
149 | # Highlight quotes by indent | ||
150 | color quoted blue black | ||
151 | color quoted1 magenta black | ||
152 | color quoted2 cyan black | ||
153 | color quoted3 yellow black | ||
154 | color quoted4 red black | ||
155 | |||
156 | # urls | ||
157 | color body brightblue black "(^|<| )mailto:[^ ]+@[^ ]( |>|$)" | ||
158 | color body brightblue black "(^|<| )(http|https|ftp|file|telnet|news|finger)://[^ ]+( |>|$)" | ||
159 | |||
160 | # *bold*, _underline_, and /italic/ | ||
161 | color body brightcyan black "(^| )\\*[^ ]+\\*( |$)" | ||
162 | color body brightcyan black "(^| )_[^ ]+_( |$)" | ||
163 | color body brightcyan black "(^| )/[^ ]+/( |$)" | ||