Aerc just sent the true / false update regardless, meaning if someone already
replied to a mail, then drafted yet another mail to the same parent the flag
would vanish. This commit fixes this behaviour.
* return empty reader instead of nil when BODY is found but server returns nil
* utf7: fix package doc comment
* imap: lower some fields + content disposition keys
* remove "should not be called directly" comments and replaced them with links to the GitHub wiki pages
* backendutil: Improve Match function
* Write NIL for empty ENVELOPE fields
* readme: add NAMESPACE extension
* server: error when selecting should unselect
* Support NIL hierarchy delimiter
* backendutil: Implement message size and lines counting
* readme: update CI badge to only show status for commits
* Fix empty envelope address fields
* server: Return proper BAD response for cancelled SASL negotiation
* Replace empty string result in ErrStatusResp.Error
* Move ErrStatusResp to the root package
* Add MailboxInfoUpdate
* Fix BodyStructure fields documented as encoded
Go pre 1.15 parsed an empty string as an error, 1.15 did not but this was
unintentional as per https://github.com/golang/go/issues/40803
Fix the comment accordingly
There is a window where a new dir entry isn't yet in the dirlist.dir.
dirlist.ensureScroll however expected to always find a valid index.
Add a check so that we don't try to scroll to a -1 index.
This change handles message parse errors by printing the error when the
user tries to view the message. Specifically only handling unknown
charset errors in this patch, but there are many types of invalid
messages that can be handled in this way.
aerc currently leaves certain messages in the msglist in the pending
(spinner) state, and I'm unable to view or modify the message. aerc also
only prints parse errors with message when they are initially loaded.
This UX is a little better, because you can still see the header info
about the message, and if you try to view it, you will see the specific
error.
The color scheme for deleted emails should now match the old design,
making it easier to see when a message is deleted.
Signed-off-by: James Pond <james@cipher.host>
Go 1.15 handles "" in the address parser as a non error case, returning
an empty list.
Prior versions returned an error, which is not what we want.
Reported-by: anianz <a.ziegler@cioplenu.de>
Tested-by: anianz <a.ziegler@cioplenu.de>
This allows us to hook into the std libs implementation of parsing related stuff.
For this, we need to get rid of the distinction between a mailbox and a host
to just a single "address" field.
However this is already the common case. All but one users immediately
concatenated the mbox/domain to a single address.
So this in effects makes it simpler for most cases and we simply do the
transformation in the special case.
The `:rmdir` command removes the current directory (`-f` is required if
the directory is not empty).
This is not supported on the notmuch backend.
An issue with the maildir backend is that some sync programs (e.g.
offlineimap) may recover the directory after it is deleted. They need
to specifically be configured to accept deletions, or special commands
need to be executed (e.g. `offlineimap --delete-folder`) to properly
delete folders.
A danger of using this on the IMAP backend is that it is possible for a
new message to be added to the directory and for aerc to not show it
immediately (due to a slow connection) - using `:rmdir` at this moment
(with `-f` if the directory already contains messages) would delete the
directory and the new message that just arrived (and all other
contents). This is documented in aerc(1) so that users are aware of
possible risks.
This piggybacks on the existing IMAP support, and uses the same
configuration format (my local testing example has the IMAP and SMTP
lines almost copy-pasted from one another).
It's a little clumsy in that a new token is negotiated for every
`Send()` command, but it's a start...
If a message date would fail to parse, the worker would never receive
the MessageInfo it asked for, and so it wouldn't display the message.
The problem is the spec for date formats is too lax, so trying to ensure
we can parse every weird date format out there is not a strategy we want
to pursue. On the other hand, preventing the user from reading and
working with a message due to the error format is also not a solution.
The maildir and notmuch workers will now fallback to the internal date, which
is based on the received header if we can't parse the format of the Date header.
The UI will also fallback to the received header whenever the date header can't
be parsed.
This patch is based on the work done by Lyudmil Angelov <lyudmilangelov@gmail.com>
But tries to handle a parsing error a bit more gracefully instead of just returning
the zero date.
This can happen for example if aerc is compiled without notmuch support but the
notmuch worker is requested.
Pushing a status message isn't good enough, as this gets overridden pretty
quickly if one has multiple accounts configured.
So we show a fullscreen error instead.
Introduce the ability to configure stylesets, allowing customization of
aerc's look (color scheme, font weight, etc). Default styleset is
installed to /path/to/aerc/stylesets/default.
Introduce the ability to configure stylesets, allowing customization of
aerc's look (color scheme, font weight, etc). Default styleset is
installed to /path/to/aerc/stylesets/default.
some people send around huge html without any newline in between.
This did overflow the default 64KB buffer of bufio.Scanner.
If something can't fit in a GB there's no hope left
Also, ignoring errors is bad mkey
If accounts.conf contains an invalid maildir url, return a nice
error instead of panicking.
Log a couple of different error cases to provide extra
information about the error to the user.
Aerc usually used the path []int{1} if it didn't know what the proper path is.
However this only works for multipart messages and breaks if it isn't one.
This patch removes all the hard coding and extracts the necessary helpers to lib.
Provide search and filter with the option to specify more flag based
conditions.
Use '-x <flag>' to search for messages with a flag (seen, answered,
flagged) and '-X <flag>' to search for messages without a flag.
When message dates failed to parse, the error displayed would try to
include the time object it failed to obtain, which would display as
something like 0001-01-01 00:00:00 UTC, which isn't of much help.
Instead, display the text we were trying to parse into a date, which
makes the problem easier to debug.