Manos Pitsidianakis
b6efb14824
melib: remove Mailbox
...
Refactor Collection from melib to hold what folders have what envelopes.
Frontend accounts will now have a FolderEntry for each logical folder
and will unify many Account fields into one and eliminate a lot of
duplicate/dead code.
2020-02-10 02:11:07 +02:00
Manos Pitsidianakis
e26ed83331
Update native-tls to 0.2.3
2020-02-10 00:09:55 +02:00
Manos Pitsidianakis
c678b16711
melib/jmap: fix macro path
2020-02-09 17:07:43 +02:00
Manos Pitsidianakis
9616fbb544
melib/maildir: fix wrong subscription status in folders
...
MaildirFolder::new() was checking for subscribed status though that is
supposed to be done in MaildirType::new()
2020-02-08 23:55:47 +02:00
Manos Pitsidianakis
b107424258
melib: update GlobMatch algorithm
...
Taken from https://research.swtch.com/glob
2020-02-08 23:55:47 +02:00
Manos Pitsidianakis
6b7dea35dc
melib/parser: fix minor encoded word error
2020-02-08 23:55:47 +02:00
Manos Pitsidianakis
6afac835e0
melib/datetime: fix overflow panic on early date input
2020-02-08 23:55:47 +02:00
Manos Pitsidianakis
f131e01bfc
Fix drawing getting stuck in empty terminal
...
Fix drawing getting stuck in loops when terminal is too small by
checking for it.
2020-02-08 23:54:15 +02:00
Manos Pitsidianakis
f5e694cf5a
Make small cosmetic fixes
2020-02-08 23:54:15 +02:00
Manos Pitsidianakis
f208948651
melib: add mailbox delete/create to IMAP
2020-02-08 23:54:14 +02:00
Manos Pitsidianakis
05b91f1c02
Remove text_processing
...
Unwrap text_processing into melib
In preparation for uploading meli as a separate crate on crates.io.
2020-02-04 17:29:55 +02:00
Manos Pitsidianakis
8b6ea8de9a
Remove ui crate
...
Merge ui crate with root crate.
In preparation for uploading `meli` as a separate crate on crates.io.
Workspace crates will need to be published as well and having a separate
`ui` crate and binary perhaps doesn't make sense anymore.
2020-02-04 17:29:55 +02:00
Manos Pitsidianakis
cd1ed5ef40
melib/mbox: replace unimplemented!() with Error
2020-01-31 03:54:58 +02:00
Manos Pitsidianakis
51d9405c72
melib/mbox: fix parse error
...
First line of an mbox message is a "From ..." header without the colon
required in RFC822. Skip it when parsing the actual e-mail.
This was lost somewhere in the commit history when mbox was added,
weird.
2020-01-31 03:54:58 +02:00
Manos Pitsidianakis
6a096dd405
Add missing copyright preambles
2020-01-31 03:54:58 +02:00
Manos Pitsidianakis
5dc477bcd5
Fix some unused etc warnings
2020-01-27 17:32:12 +02:00
Manos Pitsidianakis
77d9cef6fc
melib/imap: small fixes
...
- Ignore final line ("M__ OK ...") when parsing FETCH response.
- Remove unnecessary import and reword some error messages
2020-01-27 15:55:01 +02:00
Manos Pitsidianakis
254028fa47
melib/threads: fix thread splintering case when inserting reply
...
When inserting reply, its thread group was re-inserted with the reply as
the root. This is a mistake as threads should never be re-inserted, only
modified.
2020-01-27 14:34:25 +02:00
Manos Pitsidianakis
dc63e1f657
Minor changes
2020-01-22 00:04:14 +02:00
Manos Pitsidianakis
1e2acd3b29
melib: add complete() method to ShellExpandTrait
...
complete(force: bool) returns String path segments that when appended to
the path will form a valid location. Example:
- User types: save-attachment 1 /t
- User presses <TAB>.
- complete() returns the suggestion: "mp/"
- User sees: save-attachment 1 /tmp/
complete() uses openat() and getdents64 syscalls hoping it's faster than
using stdlib.
2020-01-21 12:02:21 +02:00
Manos Pitsidianakis
6d9f584de3
Update nix to 0.16.1
2020-01-21 12:02:21 +02:00
Manos Pitsidianakis
a9842cacee
ui: add theming support
...
Configuration flag "terminal.themes" has two default theme entries,
"dark" and "light".
This commit alters only CompactListing for theme support.
2020-01-21 12:02:21 +02:00
Manos Pitsidianakis
e07b5faf6e
melib/threads: already-exists check in threads insert
2020-01-20 16:03:29 +02:00
Manos Pitsidianakis
350fafb515
melib/thread: add attachments field to Thread
2020-01-20 16:03:06 +02:00
Manos Pitsidianakis
5e68d600b9
melib/threads: Split ThreadGroup::Group to Thread
...
Create Thread struct.
2020-01-20 16:03:06 +02:00
Manos Pitsidianakis
d9269335a1
melib/threads: rename thread hashes
...
- Rename ThreadHash to ThreadNodeHash
- Rename ThreadGroupHash to ThreadHash
2020-01-20 16:03:06 +02:00
Manos Pitsidianakis
47a69f8eb9
melib: add ThreadGroup
...
Instead of using Union/Find to gather mail that belongs in the same
e-mail thread together, add a new entity ThreadGroup that ThreadNodes
point to. ThreadGroup represents an actual Thread: A thread root
ThreadGroup::Group or a reply ThreadGroup::Node.
To make semantics more accurate:
- ThreadNode hash should be renamed to ThreadNodeHash
- ThreadGroupHash should be renamed to ThreadHash
- ThreadGroup::Group should be a struct named Thread instead
- move ThreadGroup::Node logic to ThreadNode akin to Union/Find
- rename ThreaddGroup::Group to Thread
2020-01-20 16:03:06 +02:00
Manos Pitsidianakis
1eb49efb22
melib/threads: use all References in thread building
...
WIP
2020-01-20 16:03:06 +02:00
Manos Pitsidianakis
56e3ea1548
melib/imap: refactor early error exit
2020-01-20 15:58:59 +02:00
Manos Pitsidianakis
7f8c638361
melib/imap: add mailbox creation ability
2020-01-20 15:58:59 +02:00
Manos Pitsidianakis
853fe14128
melib: fix two minor email parsing bugs
...
- windows-1250 encoding not being recognized
- spaces in Message-ID header messing up parsing '<' + msg-id + '>'
structure
2020-01-20 15:58:59 +02:00
Manos Pitsidianakis
6835968d9a
melib/datetime: convert date to utc before converting to unix epoch
2020-01-20 15:58:59 +02:00
Manos Pitsidianakis
a365a846b8
Replace StackVec with smallvec::SmallVec
...
SmallVec has a less buggy and better implementation.
2020-01-20 15:58:59 +02:00
Manos Pitsidianakis
ca7d72e732
melib: Replace String with Cow<'static, str>
2020-01-07 12:55:27 +02:00
Manos Pitsidianakis
9fcc868acd
remove chrono
2020-01-06 16:11:46 +02:00
Manos Pitsidianakis
c0ac643f05
melib: add datetime module
...
Datetime module adds POSIX time functions interface
2020-01-06 16:10:36 +02:00
Manos Pitsidianakis
6671fe926e
melib: don't treat missing end boundary as error
...
Don't treat missing end boundary as error in multipart attachments.
python3's nntplib seems to return MIME attachments with this property
2020-01-02 00:09:21 +02:00
Manos Pitsidianakis
8694278369
ui: add auto_choose_multipart_alternative
...
Choose text/html by default if text/plain is empty in
multipart/alternative attachments
This happens in some newsletters I've come upon
2020-01-02 00:08:21 +02:00
Manos Pitsidianakis
3d84f3b9ad
notmuch: remove needless clones
2020-01-02 00:05:36 +02:00
Manos Pitsidianakis
21526b5faf
melib: make Work use FnOnce closures
...
There was no need to use Fn() instead of FnOnce()
2019-12-20 00:53:43 +02:00
Manos Pitsidianakis
92826f982f
melib/attachments: add MultipartType::Related kind
2019-12-18 15:45:50 +02:00
Manos Pitsidianakis
9211913405
meli/backends: honor mailbox subscriptions in IMAP/JMAP
2019-12-18 15:44:44 +02:00
Manos Pitsidianakis
7eceef93e9
melib/backends: remove folder_operation
...
folder_operation functionalities will go to BackendFolder trait
2019-12-18 15:43:30 +02:00
Manos Pitsidianakis
9080e0fd96
melib: rename FolderConf rename
field to alias
2019-12-18 15:40:57 +02:00
Manos Pitsidianakis
c23cc45edd
melib: fix test import not found
2019-12-18 08:59:04 +02:00
Manos Pitsidianakis
2b6f6ab42c
melib: Add BackendFolder methods, move special usage logic to backend
...
- add count() method to return (unseen, total) counts
- add is_subscribed()
- add set_special_usage() and set_is_subscribed()
concerns #8
2019-12-18 08:58:49 +02:00
Manos Pitsidianakis
8f63572584
Small refactors to avoid implicit unwrap() panics
2019-12-15 19:47:42 +02:00
Manos Pitsidianakis
0201241786
melib/backends: MailBackend::refresh() returns Result
...
Handle cases were refresh() would fail properly. Fixes a crash reported in #13
2019-12-15 08:55:08 +02:00
Manos Pitsidianakis
65efb23f14
melib/MailBackend: add refresh() method
...
Initiate refresh manually.
2019-12-14 18:58:59 +02:00
Manos Pitsidianakis
d2b4057b7b
melib/MailBackend: add connect() method
2019-12-14 18:58:55 +02:00