Commit Graph

120 Commits

Author SHA1 Message Date
Manos Pitsidianakis
9f783d9a07
meli/Cargo.toml: pin assert_cmd ver to 2.0.13
Version 2.0.14 onwards raises MSRV which is newer than the one we
support.

Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2024-07-15 13:46:21 +03:00
Manos Pitsidianakis
073aef8671
Fix lints/errors when compiling specific feature combos
- Building with sqlite3 non-bundled may result in compile-time error if
  the system version is not new enough; the bindgen feature must be
  enabled to create ffi bindings from the system version.
- Some unused code warnings show up if some features are disabled,
  refactor code to make them go away.
- Update libloading to 0.8 to prevent dual dependencies in
  Cargo.lock (rusqlite's bundled feature requires it)

Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2024-07-13 18:30:35 +03:00
Manos Pitsidianakis
39e903b1d3
melib/utils: fix issues with ShellExpandTrait
ShellExpandTrait was not expanding paths properly: tilde was expanded
even if it wasn't the first byte in the sequence. Since $HOME tends to
be an absolute path, the entire value of the path accumulator up till
that point was overwritten, meaning a /path/to/~/some/file would get
expanded to ${HOME}/some/file.

ShellExpandTrait was also not completing paths properly, especially
between the generic impl and the linux specialized one. This commit adds
test to make sure their behavior is synced and changes the result type
to an enum to make the result more descriptive.

Concerns #431.

Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2024-07-07 22:38:47 +03:00
Manos Pitsidianakis
9daf943758
meli/tests: add test_cli_subcommands.rs
Add test to catch any failure of CLI subcommand.

Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2024-06-30 16:45:44 +03:00
Manos Pitsidianakis
fe604bf0ea
Update "openssl" dependency to 0.10.64
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2024-06-28 11:15:07 +03:00
Manos Pitsidianakis
c99633e141
Update futures dependency 0.3.28 -> 0.3.30
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2024-06-28 11:14:05 +03:00
Damian Poddebniak
a8956bafc8 chore: Update to imap-codec v2.0.0-alpha.1 2024-06-08 17:49:55 +03:00
Manos Pitsidianakis
f1332e82b6
Bump version to 0.8.6
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2024-06-08 11:55:13 +03:00
Manos Pitsidianakis
671d35e21e
melib: update mailin-embedded dependency to 0.8.2
Closes: #391

Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2024-05-16 08:49:00 +02:00
Manos Pitsidianakis
8fff740176
Update yanked zerocopy dependency
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2024-05-06 19:15:58 +03:00
Manos Pitsidianakis
8eaf03554f
Bump version to 0.8.5
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2024-05-06 18:37:30 +03:00
Manos Pitsidianakis
11a0586d56
Remove num_cpus dependency
Functionality already exists in standard library with std:🧵:available_parallelism()

Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2024-04-20 16:17:01 +03:00
Manos Pitsidianakis
dedee908d1
Update notify dep from 4.0.17 to 6.1.1
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2024-04-11 21:48:30 +03:00
Manos Pitsidianakis
255e93764a
Update linkify dep from 0.8.1 to 0.10.0
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2024-04-11 21:48:25 +03:00
Manos Pitsidianakis
51e3f163d4
melib/jmap: Use Url instead of String in deserializing
Catch invalid URLs at the parsing stage.

Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2024-02-13 14:13:53 +02:00
Manos Pitsidianakis
70fc2b455c
Update nix dependency to 0.27
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2024-02-11 17:13:05 +02:00
Manos Pitsidianakis
f0866a3965
meli: make config error more user-friendly
If `send_mail` is incorrect, display a long-ish list of valid examples.

Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2023-12-29 19:51:45 +02:00
Manos Pitsidianakis
7412c23870
Bump meli version to 0.8.5-rc.3
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2023-12-11 13:18:50 +02:00
Manos Pitsidianakis
da251455a0
Bump meli version to 0.8.5-rc.2
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2023-12-04 17:25:22 +02:00
Manos Pitsidianakis
d16afc7d8d
Bump version to 0.8.5-rc.2
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2023-12-04 17:22:56 +02:00
Manos Pitsidianakis
10c3b0eabe
Bump version to 0.8.5-rc.1
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2023-12-02 19:20:34 +02:00
Manos Pitsidianakis
f81a1e2338
Bump version to 0.8.4
0.8.3 had a misbehaving test.

Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2023-11-22 21:48:59 +02:00
Manos Pitsidianakis
111a1160ad
Bump version to 0.8.3
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2023-11-22 15:39:58 +02:00
Manos Pitsidianakis
7387b67eee
Enable "static" build for C library dependencies by default
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2023-11-22 15:26:16 +02:00
Manos Pitsidianakis
af241d25cb
melib: bump version to 0.8.3
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2023-11-22 15:13:03 +02:00
Manos Pitsidianakis
43bfd4131d
Update ahash dependency
Previous one was yanked.

Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2023-11-22 14:53:46 +02:00
Manos Pitsidianakis
3d85ca2edf
Bump version to 0.8.2
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2023-09-22 12:30:54 +02:00
Manos Pitsidianakis
7eed82783a
Bump version to 0.8.1
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2023-09-13 19:08:21 +03:00
Manos Pitsidianakis
6476985ce6
Add Cross.toml for aarch64-unknown-linux-gnu builds
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2023-09-05 15:33:28 +03:00
Manos Pitsidianakis
a615b4701b
dependencies: embed xdg-utils crate
No reason to have it out of the tree.

Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2023-09-03 10:13:25 +03:00
Manos Pitsidianakis
2dc2940586
melib/build.rs: add feature to use cache instead of downloading unicode data
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2023-09-01 15:55:43 +03:00
Manos Pitsidianakis
46636d8748
Bump version to 0.8.0
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2023-08-29 15:04:55 +03:00
Damian Poddebniak
5459a84f3d chore: Update to imap-codec 1.0.0 (w/o -beta) 2023-08-28 18:16:48 +02:00
Manos Pitsidianakis
4d22b669bf
Cargo.lock: update dependencies
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2023-08-25 08:25:12 +03:00
Manos Pitsidianakis
974b3a5305
Update bitflags, rusqlite dependencies
Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
2023-08-25 08:22:36 +03:00
Damian Poddebniak
4f6081b663 chore: Update to imap-codec 1.0.0-beta. 2023-08-17 17:36:13 +02:00
Manos Pitsidianakis
97d3686815
melib/connections: use Happy Eyeballs algorithm Ꙭ
This commit adds a Happy Eyeballs [1] implementation taken from the
happy-eyeballs crate, which is in public domain.

While the function lookup_ip[0] iterates through the addresses returned by
A and AAAA records from a DNS lookup, it returns the first one  which
always is an IPv4 address, unless there only is an AAAA record.

RFC6555 [1] recommends an algorithm for choosing the fastest address to
connect to, called "Happy Eyeballs". Ꙭ

[0]: melib/src/utils/connections.rs:497
[1]: https://www.rfc-editor.org/rfc/rfc6555

Fixes #268
2023-08-15 09:55:46 +03:00
Manos Pitsidianakis
6280bc75e5
melib/jmap: fix blob download URL formatting 2023-07-18 16:13:58 +03:00
Manos Pitsidianakis
b0e867eb68
Move src to meli/src 2023-07-08 13:58:32 +03:00
Damian Poddebniak
7c33f8999b chore: Use published imap-codec 0.10.0. 2023-07-05 14:46:39 +02:00
Damian Poddebniak
9d51b6bd52 chore: Update imap-codec. 2023-07-04 20:56:51 +02:00
Manos Pitsidianakis
957abf4e72
Update cargo dependencies
Concerns #242 - "Compilation failure on master on OpenBSD"
2023-07-04 00:21:16 +03:00
Manos Pitsidianakis
0b258a1f05
meli: clippy lint fixes 2023-07-03 09:38:51 +03:00
Manos Pitsidianakis
4da5366959
Remove bincode dep, use serde_json for sqlite3 values 2023-06-17 20:11:12 +03:00
Damian Poddebniak
330887c4f5
refactor: Introduce imap-codec. 2023-06-17 20:10:21 +03:00
Manos Pitsidianakis
8c671935f9
Add compose (pre-submission) hooks for validation/linting
compose-hooks run before submitting an e-mail.
They perform draft validation and/or transformations.
If a hook encounters an error or warning, it will show up as a notification.
The currently available hooks are:
- past-date-warn
  Warn if Date header value is far in the past or future.
- important-header-warn
  Warn if important headers (From, Date, To, Cc, Bcc) are missing or invalid.
- missing-attachment-warn
  Warn if Subject, draft body mention attachments but they are missing.
- empty-draft-warn
  Warn if draft has no subject and no body.

They can be disabled with [composing.disabled_compose_hooks] setting.
2023-05-16 17:31:56 +03:00
Manos Pitsidianakis
85d4316a6a
Replace old logging module with the log create 2023-05-01 16:22:35 +03:00
Manos Pitsidianakis
3adf72aed0
Add support for utf-7 encoding
Closes #175
2023-04-10 10:33:46 +03:00
Manos Pitsidianakis
3688369278 melib/smtp: add smtp test 2022-09-10 21:39:56 +03:00
Manos Pitsidianakis
a73885acb1 Improve embed terminal
- Add character attribute support
- Add cursor key mode support
- Fix buggy set fg / bg sequences

And added a bin under tools to test arbitrary apps using the embedded
terminal:

 cargo run -p tools --bin embed -- "htop" 2> .htop.debug.log
2022-09-01 22:24:01 +03:00