aboutsummaryrefslogtreecommitdiffstats
path: root/worker
Commit message (Collapse)AuthorAgeFilesLines
* notmuch: translate filter/search options to queryKoni Marti2023-06-172-4/+106
| | | | | | | | | | | | | | | | Translate the regular filter and search options to a notmuch query to achieve a basic equivalence across backends for these commands. The following examples have the same filtering effect: :filter -uf koni :filter -u from:koni :filter tag:unread from:koni And ':filter -x Flagged' would translate to ':filter tag:flagged'. Fixes: https://todo.sr.ht/~rjarry/aerc/177 Signed-off-by: Koni Marti <koni.marti@gmail.com> Tested-by: Inwit <inwit@sindominio.net>
* logging: remove ultra verbose trace logsRobin Jarry2023-06-124-42/+2
| | | | | | | | | | | | | | | | | Every message exchanged between the UI and the worker(s) is logged at least twice with some obscure IDs and struct pointer names. When enabling trace logging, this floods the files for very little or no benefit and makes the meaningful logging message hard to catch. Also, other messages tend to flood the output for no specific reason. These are most of the time leftovers from the development process and are not useful for tracking potential issues. Remove these. Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Inwit <inwit@sindominio.net>
* mbox: use named loggerRobin Jarry2023-06-121-10/+10
| | | | | | | | Use the worker's logging functions to have all mbox related messages prefixed by the account name. Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Inwit <inwit@sindominio.net>
* notmuch: use named loggerRobin Jarry2023-06-122-36/+35
| | | | | | | | Use the worker's logging functions to have all notmuch related messages prefixed by the account name. Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Inwit <inwit@sindominio.net>
* maildir: use named loggerRobin Jarry2023-06-122-40/+40
| | | | | | | | Use the worker's logging functions to have all maildir related messages prefixed by the account name. Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Inwit <inwit@sindominio.net>
* imap: use named loggerRobin Jarry2023-06-129-48/+47
| | | | | | | | Use the worker's logging functions to have all imap related messages prefixed by the account name. Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Inwit <inwit@sindominio.net>
* worker: use named loggerRobin Jarry2023-06-121-8/+30
| | | | | | | Add a named logger for each worker based on the account name. Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Inwit <inwit@sindominio.net>
* maildirpp: fix path separatorKoni Marti2023-05-201-3/+0
| | | | | | | | | | Fix path separator for the maildir++ backend. Maildir++ already substitutes '.' for os.PathSeparator. Returning '.' will thus break the directory tree and the other logic for this backend. Fixes: 2040fc18 ("imap: use delimiter from server") Signed-off-by: Koni Marti <koni.marti@gmail.com> Acked-by: Robin Jarry <robin@jarry.cc>
* ui: fix deadlocks in message channelRobin Jarry2023-05-201-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There are several ways the ui message channel can fill up leading to deadlocks. 1) Invalidate() changes the value of uiState to DIRTY. The following call sequence: QueueRedraw() Invalidate() QueueRedraw() Leads to multiple nil messages being queued in the message channel whereas one could assume that the second QueueRedraw() would do nothing. This is caused by the tri-state nature of uiState. 2) We use the same channel to convey state change, keyboard events and redraw requests. Since a keyboard event almost always triggers a redraw, we end up trying to append a redraw message in the same goroutine that reads from the channel. This triggers a deadlock when there are more than 50 pending messages. Solve the issue by using multiple channels, one per type of message that needs to be sent to the main ui thread. Remove QueueRedraw() and merge its functionality in Invalidate(). Only use a DIRTY/CLEAN state to determine if something needs to be queued in the redraw channel. Use a channel for quitting instead of an atomic. Restructure some code functions to have a cleaner API. Use a for loop in the main thread and select from all channels. Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Koni Marti <koni.marti@gmail.com> Tested-by: Maarten van Gompel <proycon@anaproy.nl>
* headers: enable partial header fetchingTim Culverhouse2023-05-168-5/+80
| | | | | | | | | | | | | | | | | | | | | | | | | | | Enable partial header fetching by creating config values for headers to specifically include, or specifically exclude. The References field will always be fetched, regardless of the include list. Envelope data is always fetched, but is not shown with :toggle-headers, since it isn't in the RFC822 struct unless explicitly included in the list. Partial headers can break the cache on changes. Update the cache tag key to include the state of the partially-fetched headers. Partial header fetching can have a significant performance increase for IMAP, and for all backends a resource improvement. Some data to support this is below. Gathered by opening aerc, selecting a mailbox with approximately 800 messages and scrolling to the end. Received measured with nethogs, RAM from btop Received | RAM ------------------------------------- All Headers | 9,656 kb | 103 MB Minimum Headers | 896 kb | 36 MB Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Moritz Poldrack <moritz@poldrack.dev> Acked-by: Robin Jarry <robin@jarry.cc>
* imap: handle the NonExistent attributeKoni Marti2023-05-161-1/+4
| | | | | | | | | | | | | | | | | | Treat the "\NonExistent" attribute similar to the "\NoSelect" one. Only list folders without the "\NonExistent" or "\NoSelect" attribute. According to RFC 9501, section 7.3.1, the "\NonExistent" attribute implies "\NoSelect". When using the LIST-STATUS extension, some servers return a "\NonExistent" flag instead of the "\NoSelect" one. We only check for the "\NoSelect" attribute, and hence, a "\NonExistent" folder will appear in the directory list and raise an error when being selected. This occurs, e.g., for gmail accounts with the "[Gmail]" folder. Signed-off-by: Koni Marti <koni.marti@gmail.com> Acked-by: Robin Jarry <robin@jarry.cc>
* imap: use delimiter from serverMoritz Poldrack2023-05-166-5/+47
| | | | | | | | | To accommodate servers that use a delimiter other than "/" ("." being a common alternative), the delimiter is fetched from the server when connecting. Signed-off-by: Moritz Poldrack <git@moritz.sh> Acked-by: Robin Jarry <robin@jarry.cc>
* maildir: fix sorting by sizeKoni Marti2023-05-161-8/+26
| | | | | | | | | | | Retrieve message size not only in the MessageInfo but also in the MessageHeaders function. The MessageHeaders function is used for an memory-optimized maildir sorting. This fixes sorting by size in the maildir backend. Fixes: f04d83e8 ("messageinfo: report message sizes") Signed-off-by: Koni Marti <koni.marti@gmail.com> Acked-by: Tim Culverhouse <tim@timculverhouse.com>
* maildir: fix FSWatcher handling of eventsTim Culverhouse2023-05-111-40/+22
| | | | | | | | | | | | | | | | | | | | Commit ef4504e6baf5 ("maildir: fix handling of FSEvents") ambitiously tried to fix handling of file system events by handling different events in "proper" ways. Distributions and OSes report these FSEvents differently which creates a large amount of edge cases on what the right handling of each individual event should be. Revert part of ef4504e6baf5 which attempts to issue different messages based on the event. Add a debounce to file system events and always trigger a Refetch of the message list. This still fixes one of the "fixes" the referenced patch attempted at, where the UI was only told to refetch if the message count increased (but if messages disappeared externally, the maildir never updated). Fixes: ef4504e6baf5 ("maildir: fix handling of FSEvents") Reported-by: Kirill Chibisov <contact@kchibisov.com> Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Tested-by: Kirill Chibisov <contact@kchibisov.com>
* maildir: fix handling of FSEventsTim Culverhouse2023-04-282-8/+44
| | | | | | | | | | | | | | | | | | | Maildir uses a filesystem watcher to watch the currently selected directory for changes, updating the UI as necessary. Not all changes get updated based on the current logic. Send a MessageInfo if the event was a Rename. Send a MessagesDeleted if the event was a Remove. Tell the UI to refetch the list if the event was a Create. Note: This leads to some unnecessary fetching in the UI, as renames also come with a Create event in most cases. Koni suggested sending the MessageInfo and having the UI perform a binary search and inserting the message in the proper position. This is optimization is left out of this series, with a TODO left in the code. Fixes: https://todo.sr.ht/~rjarry/aerc/171 Fixes: 91ac21ac6155 ("msgstore: fetch message list based on OpenDirectory msg") Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Robin Jarry <robin@jarry.cc>
* imap: avoid error log when pruning cache entriesRobin Jarry2023-04-271-2/+4
| | | | | | | | | | | | | | Avoid such errors in the logs: ERROR cache.go:187: cannot clean database 0: unexpected EOF The cache now contains a tag mapped to a special key. This is not a gob serialized cached header. Ignore it when pruning old cache entries. Fixes: 6ea0f18635a8 ("imap: clear cache on tag mismatch") Signed-off-by: Robin Jarry <robin@jarry.cc> Acked-by: Tim Culverhouse <tim@timculverhouse.com>
* imap: add size field to cache structKoni Marti2023-04-261-1/+4
| | | | | | | Add size field to the cache struct and increment cache tag. Signed-off-by: Koni Marti <koni.marti@gmail.com> Acked-by: Robin Jarry <robin@jarry.cc>
* imap: clear cache on tag mismatchKoni Marti2023-04-261-2/+41
| | | | | | | | | Tag the imap cache and clear it when the cache tag does not match the current tag in the code. This ensures that the cache structure is always consitent with our code base. Signed-off-by: Koni Marti <koni.marti@gmail.com> Acked-by: Robin Jarry <robin@jarry.cc>
* messageinfo: report message sizesKoni Marti2023-04-265-4/+66
| | | | | | | Report sizes of the message across all backends. Signed-off-by: Koni Marti <koni.marti@gmail.com> Acked-by: Robin Jarry <robin@jarry.cc>
* search: handle headers in search/filter queryJulian Marcos2023-04-223-3/+21
| | | | | | | | | Handle headers in the search and filter commands, for searching and filtering based on the Headers specified by the -H parameter, the syntax for the -H parameter should be `Header: Key`. Signed-off-by: Julian Marcos <jmjl@tilde.green> Acked-by: Robin Jarry<robin@jarry.cc>
* directory: add IANA mailbox rolesTim Culverhouse2023-04-222-3/+20
| | | | | | | | | | | Add IANA registered mailbox role, and a custom aerc role "query". This will be used in subsequent commits which add the Role field to templates, allowing users to style mailbox by IANA role, or style notmuch queries differently than maildir dirs when using the notmuch worker + maildir option. Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Robin Jarry<robin@jarry.cc>
* directory: use directory to store rue countsTim Culverhouse2023-04-225-28/+9
| | | | | | | | | | | | Store the Directory RUE counts on the Directory data model. Use DirectoryInfo messages to update the Directory model. Access Directories via the dirlist instead of via the msgstore. Remove unused fields on DirectoryInfo, all backends now give accurate counts. Move refetch logic into dirlist Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Robin Jarry<robin@jarry.cc>
* imap: update directory on flag opsTim Culverhouse2023-04-221-0/+3
| | | | | | | | | | All other backends automatically update directory counts by sending a directory info when a flag operation is performed. Unify the imap backend to this model by posting a CheckMail action, which requests an updated status from the server and posts a DirectoryInfo message Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Robin Jarry<robin@jarry.cc>
* directory: remove attributes fieldTim Culverhouse2023-04-224-12/+6
| | | | | | | Remove the unused field Attributes Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Robin Jarry <robin@jarry.cc>
* msgstore: create from types.Directory messageTim Culverhouse2023-04-221-0/+7
| | | | | | | | | | | | | | | Create msgstores when a types.Directory message is received. This removes a quirk from the IMAP worker that msgstores are created on the first DirectoryInfo, and updated on the second. This path requires three messages in order to get an updated message store. By creating from types.Directory, we ensure that any subsequent DirectoryInfo can be routed to a msgstore. Remove the field DirInfo from the msgstore initializer, it isn't needed at initialization and isn't available with this refactor. Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Robin Jarry <robin@jarry.cc>
* capabilities: report capabilities from backendTim Culverhouse2023-04-228-18/+46
| | | | | | | | | | | | | Use the Backend interface to report Backend capabilities. Previously, these were reported via a DirectoryInfo message, however they have nothing to do with a directory and should be reported directly by the backend. Add Capabilities method to Backend interface, satisfy this in each backend, and use it on the UI side. Remove Caps field from DirectoryInfo Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Robin Jarry<robin@jarry.cc>
* imap: properly handle mailbox status updatesTim Culverhouse2023-04-222-15/+11
| | | | | | | | | | | | | | | | | | | | Mailbox status updates received from the IMAP server do not come with the information being sent to the UI. Use the update signal to instead trigger a check-mail of the directory the status was sent for. The status update comes with the following data: - Messages in the mailbox - Recent messages in the mailbox - Sequence number of the first Unseen message - Flags in the mailbox The data we actually we want to send to the UI: - Messages in the mailbox - Recent messages in the mailbox - Unseen messages in the mailbox Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Robin Jarry <robin@jarry.cc>
* msgstore: fetch message list based on OpenDirectory msgTim Culverhouse2023-04-225-11/+13
| | | | | | | | | | | | | | | Fetching the message list is done in a convoluted way. The UI receives a DirectoryInfo message, which creates a message store. It then receives a second DirectoryInfo (an oddity from the IMAP worker), and this DirectoryInfo is passed to the message store which then requests a fetch of the message list via store.Sort. Use the OpenDirectory done response to tell the message store to fetch messages. This makes the code easier to follow, and does not rely on quirks from the IMAP worker. Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Robin Jarry <robin@jarry.cc>
* parse msg-id lists more liberallyNguyễn Gia Phong2023-03-263-21/+8
| | | | | | | | | | | | | | | Some user agents deliberately generate non-standard message identifier lists in In-Reply-To and References headers. Instead of failing silently, aerc now falls back to a desperate parser scavaging whatever looking like <id-left@id-right>. As the more liberal parser being substituted with, References header are now stored for IMAP not only when there's a parsing error. Fixes: 31d2f5be3cec ("message-info: add explicit References field") Signed-off-by: Nguyễn Gia Phong <mcsinyx@disroot.org> Acked-by: Robin Jarry <robin@jarry.cc>
* fswatcher: fix bsd supportRobin Jarry2023-03-106-20/+14
| | | | | | | | | | | | | | | Fix the following error when running maildir on freebsd: could not create file system watcher: Unsupported OS: freebsd Do not register based on os type. Register based on supported API. Rename linux -> inotify and darwin -> fsevents. Only build fsevents on darwin, and inotify on all other platforms. Fixes: a0935a3de0ce ("worker/lib: implement an fswatcher interface") Reported-by: Jens Grassel <jens@wegtam.com> Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Jens Grassel <jens@wegtam.com>
* notmuch: use fswatcher to trigger directory count updateTim Culverhouse2023-03-073-13/+37
| | | | | | | | | | | Use fswatcher to watch the underlying notmuch db to trigger directory updates. Remove unused argument in the handleUpdateDirCounts function. Call this function when listing directories to initialize counts when starting aerc. Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Tested-by: Ben Lee-Cohen <ben@lee-cohen.com> Acked-by: Robin Jarry <robin@jarry.cc>
* notmuch/checkmail: simplify check-mail functionTim Culverhouse2023-03-071-19/+9
| | | | | | | | | Simplify the check-mail function in the notmuch worker. Add account name to the logs. Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Tested-by: Ben Lee-Cohen <ben@lee-cohen.com> Acked-by: Robin Jarry <robin@jarry.cc>
* fswatcher: add a darwin fswatcher implementationTim Culverhouse2023-03-073-0/+94
| | | | | | | | | | Add a darwin implementation of FSWatcher using the fsevents package. The implementation is behind a darwin build flag. Co-authored-by: Ben Cohen <ben@bencohen.net> Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Tested-by: Ben Lee-Cohen <ben@lee-cohen.com> Acked-by: Robin Jarry <robin@jarry.cc>
* maildir: use FSWatcher interfaceTim Culverhouse2023-03-072-13/+8
| | | | | | | | Use the FSWatcher interface to create the watcher. Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Tested-by: Ben Lee-Cohen <ben@lee-cohen.com> Acked-by: Robin Jarry <robin@jarry.cc>
* worker/lib: implement an fswatcher interfaceTim Culverhouse2023-03-073-0/+113
| | | | | | | | | | | Implement an FSWatcher interface. The interface is used to abstract away file system watchers, which have implementation specific backends. The initial interface has one implementation: inotify for linux. Subsequent commits will add a macOS watcher. Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Tested-by: Ben Lee-Cohen <ben@lee-cohen.com> Acked-by: Robin Jarry <robin@jarry.cc>
* lint: always run golangci-lint@latestRobin Jarry2023-02-261-1/+1
| | | | | | | | | | | | Do not store the dependency in tools.go as there may be conflicts with some indirect dependencies of aerc. Run gofumpt and golangci-lint from their latest tagged release. This should fix issues with go 1.20. Bonus, it drains a bit of fat from go.sum. Signed-off-by: Robin Jarry <robin@jarry.cc> Acked-by: Moritz Poldrack <moritz@poldrack.dev>
* log: log account name in worker message logsTim Culverhouse2023-01-291-8/+8
| | | | | | | Add account name to log of all Post/Process Message/Action logs. Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Robin Jarry <robin@jarry.cc>
* imap,smtp: cache and cycle XOAUTH2 refresh tokenDean2023-01-261-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Normally for emails with xoauth2, the help page says to pass the refresh token as the password. When the refresh token expires, aerc can't fetch the access token, and you must get a new refresh token from the external script. This patch implements a cycle of refresh tokens so you only need to use an external script to fetch the refresh token once. Once you have fetched the initial refresh token (with an external script like mutt_xoauth2.py or https://github.com/gaoDean/oauthRefreshToken), that refresh token is inputted as the password to aerc (as normal) to fetch the access token. Before this patch aerc used to only fetch the access token, but now it fetches that and a new refresh token, which it caches in $XDG_CONFIG_HOME/aerc/<account>-xoauth2.token. In the next opening of aerc, aerc will pull the refresh token from the cache, and use it instead of the inputted refresh token from the password. If it is not present in the cache, the refresh token is taken from the password as usual. Signed-off-by: Dean <gao.dean@hotmail.com> Acked-by: Robin Jarry <robin@jarry.cc>
* lint: add missing panic handlers in goroutinesRobin Jarry2023-01-067-0/+13
| | | | | | | | These issues were all reported by the new custom analyzer introduced in previous commit. Signed-off-by: Robin Jarry <robin@jarry.cc> Tested-by: Bence Ferdinandy <bence@ferdinandy.com>
* model: change flags array to bitmaskRobin Jarry2023-01-0417-107/+70
| | | | | | | Using a list of integers is not optimal. Use a bit mask instead. Signed-off-by: Robin Jarry <robin@jarry.cc> Acked-by: Tim Culverhouse <tim@timculverhouse.com>
* maildir: send MessagesDeleted to UI when moving messagesTim Culverhouse2022-12-141-0/+4
| | | | | | | | | | | | | | The maildir worker sends a MessagesMoved message to the UI when messages are moved, enabling the destination directory to update it's counts. The filesystem watcher sees the move and updates the directory currently selected. However, an update of the UIDs in the msgstore is not completed as it is in other workers. All other works, via some mechanism (direct or EXPUNGE update) issue a MessagesDeleted message after a move. Send this message to the UI for the maildir worker to have it work as all other workers do. Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Tested-by: Bence Ferdinandy <bence@ferdinandy.com>
* imap: use list-status for check-mailTim Culverhouse2022-12-021-24/+43
| | | | | | | | | Use list-status to perform check-mail commands, if it is available. This provides a significant performance benefit by only requiring one IMAP command vs one command for each mailbox. Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Robin Jarry <robin@jarry.cc>
* imap: use list-status for list-directories if availableTim Culverhouse2022-12-021-8/+48
| | | | | | | | | Use the LIST-STATUS extension when listing directories. This enables the UI to show message counts for every mailbox, in a similar behavior to the maildir and notmuch backends. Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Robin Jarry <robin@jarry.cc>
* imap: check for list-status capabilityTim Culverhouse2022-12-021-3/+16
| | | | | | | | | | | | | Check for LIST-STATUS capability on IMAP servers. This will be used in subsequent commits for improved check-mail performance. The LIST-STATUS command allows the LIST command to also return STATUS responses, which include message counts. Upgrade go-imap to latest release. Add go-imap-liststatus extension. Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Robin Jarry <robin@jarry.cc>
* imap: add LIST-STATUS extensionTim Culverhouse2022-12-021-0/+149
| | | | | | | | Add IMAP extension LIST-STATUS handling to IMAP worker. Reference: https://www.rfc-editor.org/rfc/rfc5819.html Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Robin Jarry <robin@jarry.cc>
* imap: simplify error handling in list directoriesTim Culverhouse2022-12-021-5/+6
| | | | | | | | Simplify the error handling in ListDirectories so the Done message is not within an else statement Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Robin Jarry <robin@jarry.cc>
* notmuch: preserve tags when moving messagesinwit2022-12-021-2/+14
| | | | | | | | Keep the original tags when a message is moved from one maildir folder to another. Signed-off-by: inwit <inwit@sindominio.net> Acked-by: Robin Jarry <robin@jarry.cc>
* notmuch: allow moving single file messagesinwit2022-12-021-9/+14
| | | | | | | | | | | | In notmuch, a message can be represented by several identical files across the maildir structure, which makes the operation of moving a message from a virtual folder (showing a notmuch query) to a maildir folder problematic if the number of files for that message is greater than 1. Since the move operation is unambiguous when the message is represented by a single file, allow moving messages in such cases. Signed-off-by: inwit <inwit@sindominio.net> Acked-by: Robin Jarry <robin@jarry.cc>
* daterange: support relative termsKoni Marti2022-12-022-5/+455
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Support relative terms when writing date ranges in the search and filter commands with the -d flag. Syntax is inspired by the notmuch search terms. Terms can be written with spaces or underscores for a better readability, so both "this_week" and "this week" are allowed. Terms are not case-sensitive. Some terms can be prefixed with either "this" or "last" where applicable ("this" is assumed by default if omitted): - "today", "yesterday" - ("this"|"last") "year", "month", "week" - all weekdays (e.g. "Tuesday", "last_wed") - all months (e.g. "January", "last_feb") Note that "month" should always be spelled out to prevent a possible ambiguity with "Monday". Weekdays and months do not need to be written out completely, i.e. "February..March" and "Feb..Mar" are both understood. Relative date terms can be used with the <N (year|month|week|day)> syntax where N is a positive integer indicating the number of time units in the past from today. The units can be abbreviated with a single letter, e.g. "1w 1d.." is the same as "1 week 1 day..". More examples: :filter -d yesterday :filter -d last_monday.. :filter -d mon..sat :filter -d 1y1m1w1d.. :search -d this_week "PATCH aerc" Signed-off-by: Koni Marti <koni.marti@gmail.com> Acked-by: Robin Jarry <robin@jarry.cc>
* imap: filter and search with a date rangeKoni Marti2022-12-021-1/+15
| | | | | | | Filter and search with a date range in the imap backend. Signed-off-by: Koni Marti <koni.marti@gmail.com> Acked-by: Robin Jarry <robin@jarry.cc>