-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmuttrc
214 lines (184 loc) · 10.3 KB
/
muttrc
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
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
### MUTT config file ###
#https://github.com/sjl/dotfiles/blob/master/mutt/muttrc
# directories and commands
set alias_file = ~/.mutt/alias # alias file
set header_cache = ~/.mutt/cache/headers # where to store headers
set message_cachedir = ~/.mutt/cache/bodies # where to store bodies
set certificate_file = ~/.mutt/certificates # where to store certs
set mailcap_path = ~/.mutt/mailcap # entrys for filetypes
set signature = ~/.mutt/sig # my signature file
set tmpdir = ~/.mutt/temp # where to keep temp files
set editor = "vim +/^$ +:s/^$/\\\\r\\\\r/ +:noh -c 'normal! k' -c 'set nolist' -c 'redraw'" # use vim
#set print_command = /usr/bin/enscript # print with enscript
# address book
#set query_command= "abook --mutt-query '%s'"
set query_command= "$HOME/.gyr.d/bin/ibm/gyr-ibm-email-search '%s'"
macro index,pager A "<pipe-message>abook --add-email-quiet<return>" "add the sender address to abook"
# main options
set mbox_type=Maildir
set folder=$HOME/Mail
set spoolfile=+/IBM/INBOX
set timeout = 3 # idle time before scanning - = 15 after 15 secs of no keypresses, start checking for new mail
set mail_check = 0 # minimum time between scans - = 120 check for new mail every 90 seconds
set sort_alias = alias # sort alias file by alias
set reverse_alias # show names from alias file in index
unset move # Move read messages to another folder?
set delete # don't ask, just do
unset confirmappend # don't ask, just do!
set quit # don't ask, just do!!
unset mark_old # read/new is good enough for me
set beep=yes # bell on new mails
set beep_new=yes # bell on new mails
set check_new
set pipe_decode # strip headers and eval mimes when piping
set thorough_search # strip headers and eval mimes before searching
# index options
set sort = threads # like gmail
set sort_aux = reverse-last-date-received # like gmail
#set sort_aux = 'last-date-received'
set uncollapse_jump # don't collapse on an unread message
set sort_re # thread based on regex
set reply_regexp = "^(([Rr][Ee]?(\[[0-9]+\])?: *)?(\[[^]]+\] *)?)*"
# pager options
set pager_index_lines = 10 # number of index lines to show
set pager_context = 5 # number of context lines to show
set pager_stop # don't go to next message automatically
set menu_scroll # scroll in menus
set smart_wrap # don't split words
set tilde # show tildes like in vim
unset markers # no ugly plus signs
auto_view text/html # view html automatically
alternative_order text/plain text/enriched text/html # save html for last
set quote_regexp = "^( {0,4}[>|:#%]| {0,4}[a-z0-9]+[>|]+)+"
# formats
set date_format = "%y%m/%d"
set index_format = "[%Z] %D %-20.20F %s"
set status_format = "-%r- %v ---[ Folder: %f, Msgs: %m%?n? New: %n?%?d? Del: %d?%?t? Tag: %t?%?l? %l? ]%?p?---- .: %p waiting to send :. ?--%>- (%P) ---"
#set status_format = "-%r-%v--[%?M?%M/?%m msgs%?n?, %n new?%?d?, %d del?%?F?, %F flag?%?t?, %t tag?%?p?, %p postp?%?b?, %b inc?%?l?, %l?]--(%f)--%s-%>-%P-"
set alias_format = "%4n %t %-20a %r"
#set alias_format = "%4n %2f %t %-12a %r"
# composing mail
set realname = "Gustavo Yokoyama Ribeiro" # who am i?
set envelope_from # which from?
set sig_dashes # dashes before my sig... sweet
set edit_headers # show headers when composing
set fast_reply # skip to compose when replying
set sendmail_wait = 0 # wait for sending, because Frontier is a steaming pile of fail
set askcc # ask for CC:
set fcc_attach # save attachments with the body
unset mime_forward # forward attachments as part of body
set forward_format = "Fwd: %s" # format for subject when forwarding
#set forward_format = "[%s]"
set forward_decode # decode when forwarding
set attribution = "On %d, %n wrote:" # set the attribution
#set attribution='On %{%a, %d %b %Y}, %n wrote:\n'
set reply_to # reply to Reply to: field
set reverse_name # reply as whomever it was to
set include # include message in replies
set forward_quote # include message in forwards
# headers to show
ignore * # ignore all headers
#unignore from: to: cc: date: subject: # show only these
unignore From:
unignore To:
unignore Reply-To:
unignore Mail-Followup-To:
unignore Return-Path:
unignore Subject:
unignore Date:
unignore CC:
unignore BCC:
unignore Importance:
#hdr_order from: to: cc: date: subject: # and in this order
hdr_order From: \
To: \
Reply-To: \
Mail-Followup-To: \
Return-Path: \
Subject: \
Date: \
CC: \
BCC: \
Importance:
# boxes
#mailboxes +IBM/INBOX +IBM/vim +IBM/clojure +IBM/django +IBM/python +IBM/mercurial +IBM/archive +IBM/sent +IBM/drafts
# always sourced
#source $alias_file # required for functionality
source ~/.mutt/colors.muttrc # source colors file
source ~/.mutt/ibm.muttrc # source IBM as default
source ~/.mutt/sidebar.muttrc # any muttng options are here
# mailboxes
source ~/.mutt/mailboxes.muttrc
# account specific sources
folder-hook IBM/* source ~/.mutt/ibm.muttrc
folder-hook . "push \eV"
# these just give me headaches
bind index,pager \# noop
bind index i noop
bind index w noop
# bindings
bind index <tab> sync-mailbox
bind index k previous-entry
bind index j next-entry
bind pager i exit
bind pager / search
bind pager k previous-line
bind pager j next-line
bind pager gg top
bind pager G bottom
bind index gg first-entry
bind index G last-entry
bind index,pager R group-reply
bind index \Cp recall-message
bind index <space> collapse-thread
# ctrl-n, ctrl-p to select next, prev folder
# ctrl-o to open selected folder
#bind index \CP sidebar-prev
#bind index \CN sidebar-next
#bind index \CO sidebar-open
#bind pager \CP sidebar-prev
#bind pager \CN sidebar-next
#bind pager \CO sidebar-open
# allow space characters in macros
bind editor <space> noop
# macros
macro index \Cr "<tag-prefix><clear-flag>N" "mark tagged messages as read"
macro index \CR "T~U<enter><tag-prefix><clear-flag>N<untag-pattern>.<enter>" "mark all messages as read"
macro index B "<limit>~b " "search message bodies"
macro index I "<change-folder>!<enter>" "go to Inbox"
macro pager \Cu "|urlview<enter>" "call urlview to extract URLs out of a message"
macro index,pager o "|mvim -c 'setlocal ft=mail' -c 'setlocal buftype=nofile' -<enter>" "open in vim"
macro index <esc>f ":set date_format = \"%m/%d\"<enter>" "short date format"
macro index <esc>F ":set date_format = \"%m/%d at %I:%M %P\"<enter>" "long date format"
# save a decoded copy in ~
macro index,pager P "<pipe-message>cat > ~/Desktop/" "save message as"
# get the url view working
macro index \cb |urlview\n 'call urlview to extract URLs out of a message'
macro pager \cb |urlview\n 'call urlview to extract URLs out of a message'
# h will take you to the folder list in the index
macro index h "c?t"
# Dump all headers
macro index p "<display-toggle-weed> <print-message> <display-toggle-weed> <exit>"
macro pager p "<display-toggle-weed> <print-message> <display-toggle-weed>"
# GPG
#source $HOME/.mutt/crypto
# smtp
set use_from = yes
# I have to set these defaults because when you first startup mutt
# it's not running folder hooks. It just starts in a folder
##### #####
##### Now a bunch of other setup #####
##### #####
set copy=yes # Whether to save sent messages
#set record=+Sent # Where to save sent messages
set ascii_chars=yes # Use ASCII arrows
set reverse_realname=yes # Reply with the name used in FROM
set status_on_top # Status bar on top.
unset collapse_unread
unset ignore_list_reply_to
# Formating
set compose_format="-- %v-- Compose [Approximate Message Size: %l Attachments: %a]%>-"
set attach_format="%u%D%I %t%4n %T%.40d%> [%.7m/%.10M, %.6e%?C?, %C?, %s] "
set folder_format="%3C %t%N %F %-8.8u %-8.8g %8s %d %f"
set message_format="%-.16n: %s"
set pager_format="~~~~~~~~~ On %{%a, %d %b %Y} at [%[%H:%M]]: %s %|~"