Commit Graph

62 Commits

Author SHA1 Message Date
flip1995 8726cb12cf [No-auto] lib/domain/mail: Fix Clippy warnings
Signed-off-by: flip1995 <hello@philkrones.com>
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-08-28 18:18:41 +02:00
flip1995 5f38265545 [Auto] lib/domain/mail: Fix Clippy warnings
Signed-off-by: flip1995 <hello@philkrones.com>
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-08-28 18:18:40 +02:00
Matthias Beyer 2185d44011 Update all dependencies
This patch updates all dependencies but not "nom".

Done with `cargo upgrade --all` and manual editing.

Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-06-30 16:44:23 +02:00
Matthias Beyer a7d53e47d1 Update toml-query to 0.9.0
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-05-29 18:39:25 +02:00
Matthias Beyer 1482f70320 Update dependency: toml: 0.4 -> 0.5
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-05-29 18:39:25 +02:00
Matthias Beyer 5c8af4460e Fix: Entries::in_collection() should be able to return error
This patch changes the Entries::in_collection() interface to return a
Result<()>. This is needed because the fs backend implementation should
be able to check whether a directory actually exists whenever we change
the iterator.

If the implementation detects that the directory does not exist, we can
fail early and error out.

All usages of the interface are adapted by the patch as well.

Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-05-18 13:37:46 +02:00
Matthias Beyer 26de159415 Add more context in error messages
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-05-18 00:55:10 +02:00
Matthias Beyer 1d89844613 Run 'cargo fix' for rust-2018
With this patch we move the codebase to Rust-2018.

The diff was generated by executing

    cargo fix --all --all-features --edition

on the codebase.

Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-05-18 00:20:59 +02:00
Matthias Beyer cb4d5367e4 Rewrite all usages of ModuleEntryPath
Because the code was so complex before, we had to create an object and
then cast that object into a `StoreId` rather than just creating a
`StoreId` object right away.

With this patch, we're using the code-generation approach to generate a
function that creates a `StoreId` object based on the name of the
current module. That's way easier and error handling was also improved
by the switch to the new implementation.

The patch also includes a rewrite of all usages of ModuleEntryPath and
changes them to `module_path::new_id()` calls.

Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-04-13 22:39:39 +02:00
Matthias Beyer ae95022202 Optimize: Do not compute lowercase key twice
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-02-28 18:07:25 +01:00
Matthias Beyer ce678d6418 Fix: Compare different variables
The bug was that we compared the variable with itself, but one time to
lowercase and one time not, so it was always false.

Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-02-24 22:33:41 +01:00
Matthias Beyer ac914b27e2 Merge branch 'libimagmail-better-hash' into master
This merges improvements for the libimagmail hasher.

Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-02-22 11:34:26 +01:00
Matthias Beyer 211d6fa60b Add helper function to be more flexible
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-02-22 11:31:58 +01:00
Matthias Beyer 596af2fc76 Reimplement the hasher
We create a sha1 over the path of the file and the Message-ID of the
mail itself.

The file name is not constant with mail files, because flags are encoded
in the filename. The path is also not constant with mail files, because
they can be moved between boxes.

This approach is not yet the best one, but better than before.

Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-02-22 11:30:12 +01:00
Matthias Beyer a819aeb6ed Rewrite libimagmail
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-02-20 16:22:52 +01:00
Matthias Beyer f84cc8169f Revert "Remove libimagmail"
This reverts commit 74045e1800.

Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-02-20 16:22:52 +01:00
Matthias Beyer 74045e1800 Remove libimagmail
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-02-17 11:09:48 +01:00
Matthias Beyer 9185abcfa5 Update copyright years
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-01-03 18:41:36 +01:00
Matthias Beyer 9fca66aa89 Forbid unsafe code in all crates 2018-11-11 13:05:55 +01:00
Matthias Beyer 4e516ee19d Update version strings
...for the next release, which will be imag 0.10.0!

Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2018-11-10 11:56:37 +01:00
Matthias Beyer e043304767 Add FileLockEntry-getter in Mail struct 2018-11-06 14:48:49 +01:00
Matthias Beyer f4ff2ba250 libimagmail: Move from error-chain to failure
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2018-10-30 18:46:29 +01:00
Matthias Beyer e8d24634e6 Update dependency: email: 0.0.17 -> 0.0.20 2018-10-06 12:22:15 +02:00
Matthias Beyer 0a7afee454 Update dependency: error-chain: 0.11 -> 0.12 2018-09-27 15:05:25 +02:00
Matthias Beyer 664edc7943 Update version string: 0.8.0 -> 0.9.0 2018-05-09 11:39:33 +02:00
Matthias Beyer 6d21d8eb49 Update dependency: filters: 0.2 -> 0.3 2018-04-29 10:46:36 +02:00
Matthias Beyer d2dceb6640 Update version numbers: 0.7.0 -> 0.8.0 2018-04-19 10:05:53 +02:00
Matthias Beyer 98f8366e4c Fix documentation in crate metadata 2018-04-17 15:55:08 +02:00
Matthias Beyer 30ad7d89b1 Reimplement libimagmail for new libimagentryref interface 2018-02-19 12:15:22 +01:00
Matthias Beyer 30d2c28a22 Update version string: 0.6.0 -> 0.7.0 2018-02-11 14:22:24 +01:00
Matthias Beyer d5a9e4930d Update dates in license header
And add missing header in one file
2018-02-07 02:48:53 +01:00
Matthias Beyer 635d000344 log: 0.4.0-rc.1 -> 0.4.0 2018-01-15 11:21:52 +01:00
Matthias Beyer f209e12410 Update dependency: log: 0.3.* -> 0.4.0-rc.1 2018-01-15 11:20:07 +01:00
Matthias Beyer 3c8dd19d11 Update version strings: 0.5.0 -> 0.6.0 2017-12-25 19:17:07 +01:00
Matthias Beyer a44d79093c Replace uses of try!() macro with "?" operator 2017-10-31 15:04:50 +01:00
Matthias Beyer a20871eb5e Add badges in Cargo.toml of all crates 2017-10-31 15:03:30 +01:00
Matthias Beyer 663242db7e Update dependency: error-chain: 0.10 -> 0.11 2017-10-12 22:12:27 +02:00
Matthias Beyer 013e82f04f Update dependency: filters: 0.1 -> 0.2 2017-10-12 19:48:01 +02:00
Matthias Beyer 046eb5eca3 Merge pull request #1108 from matthiasbeyer/libimagentryref/refactor-errors
Refactor errors to use error-chain linking functionality
2017-09-24 15:23:04 +02:00
Matthias Beyer 2ce75251d9 Adjust for new error linking setup in libimagentryref 2017-09-24 13:05:16 +02:00
Matthias Beyer 73f6016221 Update version strings: 0.4.0 -> 0.5.0 2017-09-24 13:05:01 +02:00
Matthias Beyer 162b36d6ee Update dependency specs
Most notably:

* env_logger: 0.4 -> 0.5
* hoedown: 5.0.0 -> 6.0.0
* itertools: 0.5 -> 0.6
* lazy_static: 0.1.15 -> 0.2
* regex: 0.1 -> 0.2
* semver: 0.5 -> 0.8
* url: 1.2 -> 1.5
* uuid: 0.3 -> 0.5

(This list is most surely not complete)
2017-09-19 17:16:19 +02:00
Matthias Beyer c115215fa4 Merge branch 'master' into libimagerror/integration
This merge solved a _LOT_ of conflicts and was a rather complicated one,
as parts of the conflict-resolution involved rewriting of half the
stuff.

This merge commit fixes all the things so a `cargo check --all`
succeeds, but I did not yet check whether tests run without failure.
2017-09-04 23:02:45 +02:00
Matthias Beyer 6d1dab3117 Merge pull request #1029 from matthiasbeyer/all-extensions-as-traits
All extensions as traits
2017-09-04 21:59:54 +02:00
Matthias Beyer 18e806f588 Remove dedicated result modules, use error chain generated Result types 2017-09-04 09:19:29 +02:00
Matthias Beyer 7ce44e8090 Remove "IntoError" trait, use error_chain functionality 2017-09-03 21:34:07 +02:00
Matthias Beyer 22cff91653 libimagmail: Rewrite error handling 2017-09-03 21:33:54 +02:00
Matthias Beyer 603808a9fa Impl IntoError for error kinds 2017-09-03 15:42:06 +02:00
Matthias Beyer a309fdb280 Add recursion limits to crates 2017-09-03 15:42:06 +02:00
Matthias Beyer 11d881d3a9 Add dependency to crates: error_chain = 0.10 2017-09-03 15:42:06 +02:00