aboutsummaryrefslogtreecommitdiffstats
path: root/worker/imap/movecopy.go
Commit message (Collapse)AuthorAgeFilesLines
* imap: drain updates channel when moving messagesKoni Marti2024-02-261-0/+3
| | | | | | | | | | | | | Drain the updates channel when moving messages to prevent a backend freeze. This also fixes a possible freeze for large-scale archive operations since the archive command uses the move operation. Reported-by: Moritz Poldrack <moritz@poldrack.dev> Signed-off-by: Koni Marti <koni.marti@gmail.com> Tested-by: Jeremy Baxter <jtbx@disroot.org> Tested-by: Moritz Poldrack <moritz@poldrack.dev> Acked-by: Robin Jarry <robin@jarry.cc>
* imap: implement MoveMessages handlingTim Culverhouse2022-08-221-0/+17
| | | | | | | | | | | | Implement MoveMessages in the imap backend. go-imap includes the MOVE Imap extension by default, and if a server does not support it the command fallsback to a copy-and-delete operation. Servers with the MOVE extension will see a slight performance increase when moving messages due to fewer round trips. The IMAP implementation uses a MessagesMoved worker message to avoid polling the destination mailbox. Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Robin Jarry <robin@jarry.cc>
* lint: apply new formatting rulesMoritz Poldrack2022-08-011-1/+0
| | | | | | | Run `make fmt`. Signed-off-by: Moritz Poldrack <git@moritz.sh> Acked-by: Robin Jarry <robin@jarry.cc>
* dirlist: update RUE counts for imap/maildir on move|copy|delete|archiveTim Culverhouse2022-06-071-0/+5
| | | | | | | | | | | | | | | | | | | When moving/copying/deleting/archiving a message in imap, the RUE counts displayed in the dirlist would not update properly. Maildir has (had) an implementation that recounts the entire directory and updates the DirectoryInfo after one of these actions. This patch implements a more efficient method of updating, and also enables it to apply to IMAP without any additional requests. Upon completion of the action, the counts are manually updated with the count of messages in the action and recent and/or unseen states of those messages. This is more efficient for maildir, because we aren't counting everything in the store. For IMAP, we get the updates for free because we are only performing the update after confirmation from the server that the action has happened. Signed-off-by: Tim Culverhouse <tim@timculverhouse.com> Acked-by: Robin Jarry <robin@jarry.cc>
* go vet: composite literal uses unkeyed fieldsMoritz Poldrack2022-03-181-2/+2
| | | | | | | | This commit fixes all occurrences of the abovementioned lint-error in the codebase. Signed-off-by: Moritz Poldrack <git@moritz.sh> Acked-by: Robin Jarry <robin@jarry.cc>
* go.mod: change base git urlRobin Jarry2021-11-051-1/+1
| | | | | | | I'm not sure what are the implications but it seems required. Link: https://github.com/golang/go/issues/20883 Signed-off-by: Robin Jarry <robin@jarry.cc>
* Mark sent messages as "seen" in maildirGalen Abell2020-03-031-1/+1
| | | | | | | - Add maildir flags to complement a messages imap flags - Set the "seen" flag on sent messages when using the maildir backend - Cleanup AppendMessage interface to use models.Flag for both IMAP and maildir
* Use []uint32 instead of imap.SeqSetBen Burwell2019-07-081-1/+2
| | | | | | | | A sequence-set is an IMAP-specific implementation detail. Throughout the UI, aerc simply operates using lists of opaque identifiers. In order to loosen the coupling between the UI and IMAP in particular, replace most usages of imap.SeqSet with []uint32, leaving the translation to a SeqSet to the IMAP backend as needed.
* s/aerc2/aerc/gDrew DeVault2019-05-171-1/+1
|
* Copy sent emails to the Sent folderDrew DeVault2019-05-151-0/+27
| | | | Or rather, to a user-specified folder
* Implement :copy (aka :cp)Drew DeVault2019-05-141-0/+16