| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Handle date ranges in the filter and search commands for searching and
filtering based on the Date: header. Implement a flag (-d) that accepts
a date range <start[..end]> where the start date is included in the
range but the end date is not, i.e. [start,end).
The start or end date can be omitted: "start", "start..", "..end", or
"start..end" are all valid inputs.
An example filter query would look like this: :filter -d 2022-11-09..
The dates should be in the YYYY-MM-DD format.
Signed-off-by: Koni Marti <koni.marti@gmail.com>
Acked-by: Robin Jarry <robin@jarry.cc>
|
|
|
|
|
|
|
|
|
|
| |
Use the same name than the builtin "log" package. That way, we do not
risk logging in the wrong place.
Suggested-by: Tim Culverhouse <tim@timculverhouse.com>
Signed-off-by: Robin Jarry <robin@jarry.cc>
Tested-by: Bence Ferdinandy <bence@ferdinandy.com>
Acked-by: Tim Culverhouse <tim@timculverhouse.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The main goal is to ensure that by default, the log file (if configured)
does not grow out of proportions. Most of the logging messages in aerc
are actually for debugging and/or trace purposes.
Define clear rules for logging levels. Enforce these rules everywhere.
After this patch, here is what the log file looks like after starting up
with a single account:
INFO 2022/11/24 20:26:16.147164 aerc.go:176: Starting up version 0.13.0-100-g683981479c60 (go1.18.7 amd64 linux)
INFO 2022/11/24 20:26:17.546448 account.go:254: [work] connected.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Tested-by: Bence Ferdinandy <bence@ferdinandy.com>
Acked-by: Tim Culverhouse <tim@timculverhouse.com>
|
|
|
|
|
|
|
|
|
| |
I don't see a point in logging with UTC time. Also, it can be confusing
since this is not explicit in the date format.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Tested-by: Bence Ferdinandy <bence@ferdinandy.com>
Acked-by: Tim Culverhouse <tim@timculverhouse.com>
|
|
|
|
|
|
|
|
| |
That may be useful to debug some filter matchers.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Tested-by: Bence Ferdinandy <bence@ferdinandy.com>
Acked-by: Tim Culverhouse <tim@timculverhouse.com>
|
|
|
|
|
|
|
|
| |
We need more logging granularity.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Tested-by: Bence Ferdinandy <bence@ferdinandy.com>
Acked-by: Tim Culverhouse <tim@timculverhouse.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This modifies the colorize script to accept a command line parameter to
change the colour theme. Currently only a solarized version is added.
Due to the nature of awk the theme has to be defined via the `-v` flag.
Due to the `switch` statement only being available in GNU awk we use a
`if else` statement to ensure that the default colours are used if
either the `THEME` variable is not set at all or set to `default`.
Solarized colour scheme: https://ethanschoonover.com/solarized/
Signed-off-by: Jens Grassel <jens@wegtam.com>
Signed-off-by: Robin Jarry <robin@jarry.cc>
|
|
|
|
|
|
|
|
| |
Add more detailed explanation of how filters work and substantially
increase number and detail of examples.
Signed-off-by: Bence Ferdinandy <bence@ferdinandy.com>
Signed-off-by: Robin Jarry <robin@jarry.cc>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Using KeysHash() does not guarantee any stable ordering of elements.
This causes random weirdness when some filters are using wildcards:
[filters]
text/plain=colorize
text/html=html
text/*=bat -fP --file-name="$AERC_FILENAME" --style=plain
When the source order is not preserved, the text/* filter may be matched
first against text/plain or text/html parts.
Use Keys() which does not create a map and preserve original ordering.
Fixes: 17bb9387c4a3 ("config: move [filters] parsing to separate file")
Signed-off-by: Robin Jarry <robin@jarry.cc>
Tested-by: Bence Ferdinandy <bence@ferdinandy.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
aerc-config(5) is getting too big and cluttered. Only keep aerc.conf
settings in it. Move binds.conf settings in aerc-binds(5) and
accounts.conf settings in aerc-accounts(5).
Adjust all references accordingly. Update the README to reference the
two new man pages. Update the Makefile to install them in proper
locations.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Koni Marti <koni.marti@gmail.com>
|
|
|
|
|
|
|
|
| |
Mention that multiple marked messages are reordered if they look like
a patch series.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Koni Marti <koni.marti@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
For consistent rendering, it is best if every man page uses the same
conventions. These are completely arbitrary and I only did some trial
& error until I found something that looked visually OK.
Update CONTRIBUTING.md with guidelines for scdoc markup conventions.
Update all man pages according to these guidelines.
Suggested-by: Inwit <inwit@sindominio.net>
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Koni Marti <koni.marti@gmail.com>
Acked-by: Inwit <inwit@sindominio.net>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Remove `Default: none` or `Default: ""` statements which may be
confusing. If there is no default value, simply do not mention a default
value.
Comment all settings in aerc.conf so that real default values are used.
Adjust man pages.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Koni Marti <koni.marti@gmail.com>
|
|
|
|
|
|
|
|
|
| |
Apparently the canon dictates that the program name be capitalized at
the top of each man page. The same doctrine seems to apply to section
headings as well.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Koni Marti <koni.marti@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Add missing periods at the end of sentences.
- Add missing setting names before examples.
- Remove double spaces after periods.
- Fix sendmail default path.
- Add missing [filters] examples in aerc-config(5).
- Add missing log-file config hint in aerc(1).
- Fix title and default filters in aerc-tutorial(7).
- Add missing empty lines after section headings.
- Fix various typos.
- Remove duplicate section in aerc-search(1).
Signed-off-by: Inwit <inwit@sindominio.net>
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Koni Marti <koni.marti@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fix the following error occurring when fetching new headers after IDLE:
panic: runtime error: invalid memory address or nil pointer dereference
bufio.(*Reader).fill(0xc00029af00)
bufio/bufio.go:106 +0xd8
bufio.(*Reader).Peek(0xc0006e1f00, 0x1)
bufio/bufio.go:144 +0x5d
github.com/emersion/go-message/textproto.ReadHeader(0x0?)
github.com/emersion/go-message@v0.15.0/textproto/header.go:525 +0x5f
git.sr.ht/~rjarry/aerc/worker/imap.(*IMAPWorker).handleFetchMessageHeaders.func1(0xc00026e980)
git.sr.ht/~rjarry/aerc/worker/imap/fetch.go:49 +0x1ab
git.sr.ht/~rjarry/aerc/worker/imap.(*IMAPWorker).handleFetchMessages.func1()
git.sr.ht/~rjarry/aerc/worker/imap/fetch.go:222 +0xa2
created by git.sr.ht/~rjarry/aerc/worker/imap.(*IMAPWorker).handleFetchMessages
git.sr.ht/~rjarry/aerc/worker/imap/fetch.go:217 +0x10a
Some IMAP messages only contain flag updates, ignore them.
Reuse the same logic than handleFetchMessageBodyPart() and
handleFechFullMessages().
Fixes: https://todo.sr.ht/~rjarry/aerc/111
Signed-off-by: Robin Jarry <robin@jarry.cc>
Tested-by: normen <normenweb@mac.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fix popover menu regression by triggering completions after the
simulated key strokes have been processed.
Commit 055c6dc6604f7f ("exline: don't draw completions for keybinds")
removed a double-draw event and reinstated the tab completions correctly
but it did not trigger the completion process again which was the
expected behavior.
Fixes: https://todo.sr.ht/~rjarry/aerc/104
Signed-off-by: Koni Marti <koni.marti@gmail.com>
Tested-by: Bence Ferdinandy <bence@ferdinandy.com>
Acked-by: Robin Jarry <robin@jarry.cc>
|
|
|
|
|
|
|
|
| |
Mention the header Labels (for showing notmuch tags in the viewer) in the
docs.
Signed-off-by: inwit <inwit@sindominio.net>
Acked-by: Moritz Poldrack <moritz@poldrack.dev>
|
|
|
|
|
|
|
|
| |
Fix parts index by making an explicit copy of the index slice.
Fixes: https://todo.sr.ht/~rjarry/aerc/103
Signed-off-by: Koni Marti <koni.marti@gmail.com>
Acked-by: Robin Jarry <robin@jarry.cc>
|
|
|
|
|
|
|
|
| |
Currently we have tab to go forward among the tabs, but not backwards.
Add backtab bound to prev-field to make the defaults symmetrical.
Signed-off-by: Bence Ferdinandy <bence@ferdinandy.com>
Acked-by: Robin Jarry <robin@jarry.cc>
|
|
|
|
|
|
|
|
| |
Draw a framed box with a title containing an interactive-drawable
widget.
Signed-off-by: Koni Marti <koni.marti@gmail.com>
Acked-by: Tim Culverhouse <tim@timculverhouse.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Open a user-defined file picker with the -m flag for the attach command
to select attachments.
Specify your file picker of choice with the 'file-picker-cmd' in the
[composer] section of aerc.conf, e.g. "file-picker-cmd=fzf -m".
A '%s' placeholder can be used in the 'file-picker-cmd' which is then
substituted for the argument <arg> provided to :attach -m <arg>.
For example, when you set 'file-picker-cmd=find %s -type f | fzf -m',
you can easily change the directory to start the search with ':attach -m
<path-to-search>'.
Tested with fzf, fzy and peco.
Implements: https://todo.sr.ht/~rjarry/aerc/108
Signed-off-by: Koni Marti <koni.marti@gmail.com>
Acked-by: Tim Culverhouse <tim@timculverhouse.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Allow configuring persistent logging to file with a log level. When
redirecting the output of aerc to a file these two settings are ignored
and all messages are printed to stdout.
Suggested-by: Moritz Poldrack <moritz@poldrack.dev>
Suggested-by: Tim Culverhouse <tim@timculverhouse.com>
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Tim Culverhouse <tim@timculverhouse.com>
|
|
|
|
|
|
|
|
|
|
| |
The config.go file is getting too big. Move the aerc.conf [triggers]
section parsing logic into a dedicated triggers.go file.
No functional change.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Moritz Poldrack <moritz@poldrack.dev>
|
|
|
|
|
|
|
|
|
|
| |
The config.go file is getting too big. Move the aerc.conf [openers]
section parsing logic into a dedicated openers.go file.
No functional change.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Moritz Poldrack <moritz@poldrack.dev>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The config.go file is getting too big. Move the aerc.conf [statusline]
section parsing logic into a dedicated statusline.go file.
No functional change.
Please ignore the casual "realignment" of fields in the default config
initialization. Thanks gofmt.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Moritz Poldrack <moritz@poldrack.dev>
|
|
|
|
|
|
|
|
|
|
| |
The config.go file is getting too big. Move the aerc.conf [viewer]
section parsing logic into a dedicated viewer.go file.
No functional change.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Moritz Poldrack <moritz@poldrack.dev>
|
|
|
|
|
|
|
|
|
|
| |
The config.go file is getting too big. Move the aerc.conf [compose]
section parsing logic into a dedicated compose.go file.
No functional change.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Moritz Poldrack <moritz@poldrack.dev>
|
|
|
|
|
|
|
|
|
|
| |
The config.go file is getting too big. Move the aerc.conf [filters]
section parsing logic into a dedicated filters.go file.
No functional change.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Moritz Poldrack <moritz@poldrack.dev>
|
|
|
|
|
|
|
|
|
|
| |
The config.go file is getting too big. Move the aerc.conf [general]
section parsing logic into a dedicated general.go file.
No functional change.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Moritz Poldrack <moritz@poldrack.dev>
|
|
|
|
|
|
|
|
|
|
| |
The config.go file is getting too big. Move the aerc.conf [templates]
section parsing logic into a dedicated templates.go file.
No functional change.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Moritz Poldrack <moritz@poldrack.dev>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The config.go file is getting too big. Move the aerc.conf [ui] section
parsing logic into a dedicated ui.go file.
Add a defaultUiConfig() function to also get the default configuration
values in a separate file.
Extract fragmented bits of code in AercConfig.parseConfig() in a new
AercConfig.parseUi() function defined in ui.go.
Change parseUiConfig() into a UIConfig.parse() method.
Change some methods receiver args to pointers to avoid unnecessary
copies.
No functional change.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Moritz Poldrack <moritz@poldrack.dev>
|
|
|
|
|
|
|
|
|
|
| |
The config.go file is getting too big. Move all binds.conf parsing logic
into binds.go where it belongs.
No functional change.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Moritz Poldrack <moritz@poldrack.dev>
|
|
|
|
|
|
|
|
|
|
| |
The config.go file is getting too big. Move accounts.conf parsing logic
into a dedicated accounts.go file.
No functional change.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Moritz Poldrack <moritz@poldrack.dev>
|
|
|
|
|
|
|
| |
For consistency with binds.conf
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Moritz Poldrack <moritz@poldrack.dev>
|
|
|
|
|
|
|
| |
There is no point in keeping an open reference to the ini file.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Moritz Poldrack <moritz@poldrack.dev>
|
|
|
|
|
|
|
|
|
| |
This may have worked at some point in time but that is not the case
anymore. To accommodate for the rework of the config module, it needs to
be removed anyway.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Moritz Poldrack <moritz@poldrack.dev>
|
|
|
|
|
|
|
|
|
|
|
|
| |
The code of Archive and Move are slightly different, even though they
essentially do the same thing sans the destination and archive always
creating the destination if it doesn't exist. Extract common code into
a function used by both. This will also result in Move now also
respecting next-message-on-delete.
Signed-off-by: Bence Ferdinandy <bence@ferdinandy.com>
Acked-by: Koni Marti <koni.marti@gmail.com>
Acked-by: Robin Jarry <robin@jarry.cc>
|
|
|
|
|
|
|
|
|
|
| |
Fallback to just using the raw In-Reply-To header content when it cannot
be properly parsed as a message-id.
Fixes: ca903d422826 ("envelope: add InReplyTo field")
Reported-by: Bence Ferdinandy <bence@ferdinandy.com>
Signed-off-by: Koni Marti <koni.marti@gmail.com>
Tested-by: Bence Ferdinandy <bence@ferdinandy.com>
|
|
|
|
|
|
|
|
|
| |
Fix mouse support for selecting folders. Toggle foldable directories to
expand or collapse when clicked on.
Fixes: https://todo.sr.ht/~rjarry/aerc/99
Signed-off-by: Koni Marti <koni.marti@gmail.com>
Tested-by: Bence Ferdinandy <bence@ferdinandy.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
My corporate email server annoyingly adds an "[External] " prefix when
delivering emails from outside my organization. I'd like to be able to
automatically strip it from the subject line when replying to external
emails.
With this patch, I can achieve it by setting this line in my account
configuration:
subject-re-pattern = ^(\[External\] : )?((?i)((AW|RE|SV|VS|ODP|R): ?)+)
Signed-off-by: jp39 <jp39@gmx.com>
Acked-by: Moritz Poldrack <moritz@poldrack.dev>
|
|
|
|
|
|
|
| |
Export some more environment variables to the pager commands.
Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Koni Marti <koni.marti@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
MessageInfo structs can be returned from the workers with parser errors.
MessageViews were previously prevented from opening if the error field
was not nil, however the addition of message view splits have allowed
these messages to have split views created. A panic can occur if a split
is open and one of these messages is scrolled over.
Prevent access to MessageInfo methods if the Error field is set.
Display the error to the user in the split view. The partSwitcher will
be nil if an error is set: check for this condition before calling it's
methods.
Reported-by: Ben Lee-Cohen <ben@lee-cohen.com>
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
Acked-by: Robin Jarry <robin@jarry.cc>
|
|
|
|
|
|
|
|
|
|
| |
Show dynamic folders from notmuch queries using :cf when using the
directory tree view. The current dirtree implementation would swallow
the query list entry but show the folder contents correctly in the
message list.
Signed-off-by: Koni Marti <koni.marti@gmail.com>
Tested-by: Inwit <inwit@sindominio.net>
|
|
|
|
|
|
|
|
|
| |
Prevent crash when no folder is found.
Fixes: https://todo.sr.ht/~rjarry/aerc/100
Fixes: https://todo.sr.ht/~rjarry/aerc/101
Signed-off-by: Koni Marti <koni.marti@gmail.com>
Tested-by: Inwit <inwit@sindominio.net>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Commit 155f0c3f28a1 ("maildir/sort: get MessageInfos in parallel") added
parallel parsing of maildir messages. The parsing is limitted to 2x the
number of CPUs using a buffered channel. The channel is drained at the
end of the parsing, however it is not drained if a parse error is
encountered. With enough errors, this can lead to a deadlock.
Drain the channel when an error occurs.
Fixes: 155f0c3f28a1 ("maildir/sort: get MessageInfos in parallel")
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
Acked-by: Robin Jarry <robin@jarry.cc>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Commit 29205fdd07c0 ("maildir/search: get MessageInfos in parallel")
introduced parallel searching of maildir backends, which improves search
and filtering performance. When no filter is specified, the search
algorithm is still used with no criteria because the FilterCriteria
field always contains "filter" as a minimum. With the new parallelized
search, the message order becomes random. Only use the search algorithm
if there is a filter specified.
If a filter *is* specified and a sort order is *not*, the messages will
go through the search algorithm and become randomized, but not sorted
back in order. Always default to a UID order sort (the same as prior to
this commit) when no sort order is specified.
Fixes: 29205fdd07c0 ("maildir/search: get MessageInfos in parallel")
Reported-by: Ben Lee-Cohen <bdc@fastmail.fm>
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
Tested-by: Ben Lee-Cohen <bdc@fastmail.fm>
|
|
|
|
|
|
|
|
| |
Add italic option to style config. Update docs.
Suggested-by: inwit <inwit@sindominio.net>
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
Tested-by: Bence Ferdinandy <bence@ferdinandy.com>
|
|
|
|
|
|
|
|
|
|
| |
Add thread capability to maildir backend. Enables the maildir worker to
thread the entire folder, as opposed to only the displayed messages via
client side threads.
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
Tested-by: Inwit <inwit@sindominio.net>
Acked-by: Robin Jarry <robin@jarry.cc>
|
|
|
|
|
|
|
|
|
|
| |
Add an explicit References field to message info. This is useful for
storing information needed for threading without storing all of the
header values, keeping system RAM usage lower.
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
Tested-by: Inwit <inwit@sindominio.net>
Acked-by: Robin Jarry <robin@jarry.cc>
|