Manos Pitsidianakis
9a29f4245f
melib/imap: add COMPRESS=DEFLATE support
...
Closes #53
2020-07-28 17:39:25 +03:00
Manos Pitsidianakis
8ec0da4fbd
melib/imap: add conf toggle flags for IMAP extensions
2020-07-27 15:06:57 +03:00
Manos Pitsidianakis
7bbfd188ef
melib/imap: move current_mailbox to ImapStream
...
ImapStream holds the connection state (current command id), so it makes
sense to move current_mailbox state there. That way, when a connection
drops for whatever reason the old current_mailbox is dropped and not
carried over to new connections.
2020-07-27 15:06:56 +03:00
Manos Pitsidianakis
32b4c30fee
melib/email.rs: use SmallVec for Address fields
2020-07-27 15:06:56 +03:00
Manos Pitsidianakis
031e81ac8f
imap: add UntaggedResponse::UIDFetch
2020-07-26 16:09:41 +03:00
Manos Pitsidianakis
f41a1ffe3a
imap: remove FLAGS.SILENT from STOREs
...
Flag updates were not received, because FLAGS.SILENT was used.
2020-07-26 16:09:41 +03:00
Manos Pitsidianakis
5a5408ecd5
imap: small fixes
2020-07-25 15:19:53 +03:00
Manos Pitsidianakis
00acba7717
melib/MailBackend: add copy_messages,set_flags,delete_messages methods
2020-07-25 15:19:53 +03:00
Manos Pitsidianakis
6121f77853
imap: support LIST-STATUS
2020-07-23 13:23:24 +03:00
Manos Pitsidianakis
350c8033b1
imap: use ImapLineIterator in imap_mailboxes()
2020-07-23 13:23:23 +03:00
Manos Pitsidianakis
e49c293b01
imap: impl DoubleEndedIterator for ImapLineIterator
2020-07-23 13:23:23 +03:00
Manos Pitsidianakis
9103d05617
melib: s/get/fetch in MailBackend methods
2020-07-18 12:34:13 +03:00
Manos Pitsidianakis
0a7f283582
imap: prevent deadlock in watch::examine_updates
...
uid_store.mailboxes was locked before calling examine_updates, which
calls examine_mailbox() which also attempts to lock uid_store.mailboxes
2020-07-17 22:45:25 +03:00
Manos Pitsidianakis
97c76cc6a1
melib/error: add ErrorKind struct
2020-07-13 21:36:55 +03:00
Manos Pitsidianakis
c7bbf7ed7e
melib: move lookup_ipv4() to connection module
2020-07-13 21:36:55 +03:00
Manos Pitsidianakis
9db6b07b71
Remove some needless clones and stuff (thanks to Clippy)
2020-07-13 21:36:55 +03:00
Manos Pitsidianakis
931863436d
imap: remove blocking imap backend, replace with async
2020-07-06 15:27:08 +03:00
Manos Pitsidianakis
a7e177586a
Fix clippy lints
2020-07-06 15:27:08 +03:00
Manos Pitsidianakis
bbedeed3e3
More imap async fixes
2020-07-06 15:27:06 +03:00
Manos Pitsidianakis
b3876113aa
BackendOp: return future in as_bytes()
2020-07-06 15:26:39 +03:00
Manos Pitsidianakis
1ddde9ccba
BackendOp: change fetch_flags() retval to future
2020-07-06 15:26:35 +03:00
Manos Pitsidianakis
ed3e66cedf
BackendOp: remove description() method
2020-07-06 15:26:03 +03:00
Manos Pitsidianakis
e06308fed2
MailBackend: change more methods to Futures
2020-07-06 15:26:00 +03:00
Manos Pitsidianakis
c82367e00d
BackendOp: Change set_{flag,tag} methods
2020-07-06 15:12:33 +03:00
Manos Pitsidianakis
8c1fc031e5
BackendOp: change fetch_flags retval to Result<Flag>
2020-07-06 15:12:11 +03:00
Manos Pitsidianakis
f8b84a192c
imap: add current_mailbox enum MailboxSelection
...
Add enum to track the currently selected Mailbox in the IMAP connection
2020-07-06 11:32:03 +03:00
Manos Pitsidianakis
91badc3960
imap: count message totals using HashSet
...
This way it's easy to know if a flag change in an envelope requires the
unseen total of a mailbox to change.
2020-06-26 21:12:56 +03:00
Manos Pitsidianakis
64e5d4af4f
imap/untagged.rs: properly queue refresh events
...
RefreshEvents where added in self.uid_store.refresh_events queue though
ImapConnection has a method add_refresh_event() that drains the queue if
possible
2020-06-23 20:11:05 +03:00
Manos Pitsidianakis
2a0ad92374
imap: don't send CRLF twice when sending LITERAL
...
This results in BAD IMAP errors, as a CRLF results in an empty command.
2020-06-23 20:11:04 +03:00
Manos Pitsidianakis
d7444a5b19
imap: recognize EXPUNGE events
2020-06-23 20:11:04 +03:00
Manos Pitsidianakis
d827ea1001
imap/connection.rs: debug print NO/BAD responses
2020-06-23 17:31:25 +03:00
Manos Pitsidianakis
fda947f8fb
imap.rs: fix two warnings
2020-06-23 17:31:25 +03:00
Manos Pitsidianakis
c08ceae97c
imap: add status_response() parser
2020-06-23 12:36:42 +03:00
Manos Pitsidianakis
c7835ccc13
imap: add mailbox_token() parser
2020-06-23 12:31:40 +03:00
Manos Pitsidianakis
c2300e8ea0
imap: update is_online flag on successful read/write
2020-06-23 12:30:10 +03:00
Manos Pitsidianakis
01e1f4111c
imap: make hostname optional in ENVELOPE address parser
2020-06-22 17:27:48 +03:00
Manos Pitsidianakis
79b2e20557
imap: add message to Badcharset, Permanentflags responses
2020-06-22 17:26:20 +03:00
Manos Pitsidianakis
3703ae762e
imap: show reason for error on invalid uid fetch response
2020-06-22 17:25:49 +03:00
Manos Pitsidianakis
af4ad19169
imap: add chain_err_summary error descriptions
2020-06-22 17:21:46 +03:00
Manos Pitsidianakis
75f9256a50
email/parser: change Error type to include error location
...
Add ParsingError type that includes a string with the location and
possibly an explanation for the error.
2020-06-20 13:14:40 +03:00
Manos Pitsidianakis
40f66f3333
imap: modify connection timeouts
2020-06-11 12:00:07 +03:00
Manos Pitsidianakis
34d782f16f
imap: Remove panic from fetch_flags
2020-06-11 11:44:04 +03:00
Manos Pitsidianakis
c7fbc5cafb
imap: remove redundant passing of AccountHash
2020-06-11 11:43:18 +03:00
Manos Pitsidianakis
2d3f49d64d
imap: index by (MailboxHash, UID) instead of just UID
...
Mailboxes can share UIDs.
2020-06-11 11:41:08 +03:00
Manos Pitsidianakis
b4dfc1f89d
imap: add experimental header caching with sqlite3
...
Add support for header caching. It is currently unstable and should not
be used. It can be turned on by specifying "X_header_caching" to true in
the IMAP account's configuration.
The header cache is saved in a sqlite3 database in your XDG_DATA_DIR,
for example:
/home/epilys/.local/share/meli/17328072387188469646_header_cache.db
Concerns #31 https://git.meli.delivery/meli/meli/issues/31
2020-06-07 14:35:20 +03:00
Manos Pitsidianakis
6ec249dd7f
melib: update nom dependency from 3.2.0 to 5.1.1
...
That was hecking exhausting
2020-06-06 23:19:07 +03:00
Manos Pitsidianakis
815ff98acc
imap: add smarter untagged reply detection
2020-05-30 14:43:44 +03:00
Manos Pitsidianakis
8648b229ad
Add AccountHash to RefreshEvent
...
Different accounts might have same inboxes with same MailboxHashes. Use
the hash of the account's name to differentiate.
2020-05-10 22:10:17 +03:00
Manos Pitsidianakis
eb701695f7
Remove fnv crate
2020-05-10 21:18:56 +03:00
Manos Pitsidianakis
c37d8bd331
imap: add mutex timeout lock and remove unwraps
2020-04-05 15:56:59 +03:00