summaryrefslogtreecommitdiffstats
path: root/lib/entry/libimagentrylink/src/external.rs
AgeCommit message (Collapse)Author
2019-05-31Move code from external libimagentrylink module to libimagentryurlMatthias Beyer
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-05-29Update dependency: toml: 0.4 -> 0.5Matthias Beyer
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-05-18Add more context in error messagesMatthias Beyer
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-05-18Run 'cargo fix' for rust-2018Matthias Beyer
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-04-13Rewrite all usages of ModuleEntryPathMatthias Beyer
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-13Fix for rust beta compilerMatthias Beyer
The beta compiler reports duplicated input: error: the item `IntoValues` is imported redundantly --> lib/entry/libimagentrylink/src/internal.rs:398:13 | 36 | use self::iter::IntoValues; | ---------------------- the item `IntoValues` is already imported here ... 398 | use internal::iter::IntoValues; | ^^^^^^^^^^^^^^^^^^^^^^^^^^ | so we fix this here. Other imports were fixed as well. Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-03-09Do not ignore errors when collecting linksMatthias Beyer
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-02-15Rewrite Store::new* API: libimagstore does not export backend typesMatthias Beyer
With this change applied, libimagstore does not export backend representing types anymore. This change is necessar because when we want to switch the `StoreId` implementation from "complex and stateful" to "Stateless and Cow<'_, &str>", we need to be able to have a type which represents a "`StoreId` plus the path of the Store itself". This "the path of the Store itself" is passed around as reference, to minimize runtime impact. Because such a type should not be exported by the libimagstore crate, we make it `pub(crate)` internally. But because the backend APIs also have to use this type, we would export the (private) type in the APIs of the backend. Because of that we make the backend API also non-visible to crate users, which also decreases the surface of the libimagstore API itself. Besides: Remove function `Link::with_base()` which is not needed anymore (was used in tests only). Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-01-03Update copyright yearsMatthias Beyer
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2018-11-26Do not use StoreId::local() hereMatthias Beyer
2018-11-06Change libimag{bookmark, entrylink} external linkingMatthias Beyer
...to report newly created entries, so that we can re-use these new entries in the library-using code (for example for ID reporting). Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2018-10-30libimagentrylink: Move from error-chain to failureMatthias Beyer
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2018-07-18replaced rust-crypto with RustCrypto cratesnewpavlov
2018-05-11Fix comment for rustc 1.26Matthias Beyer
2018-05-01Fix for passing Arc<_> to store interface instead of Box<_>Matthias Beyer
2018-04-25Derive Default for InMemoryFileAbstraction, remove constructorMatthias Beyer
2018-02-07Update dates in license headerMatthias Beyer
And add missing header in one file
2018-01-15env_logger: 0.4.* -> 0.5.0-rc.1Matthias Beyer
2018-01-13libimagentrylink: Replace read with typed readMatthias Beyer
2017-12-24Refactor libimagrt+libimagstore to pass whole configuration objectMatthias Beyer
Before we extracted the store configuration from the configuration toml::Value object and passed it to the store. This is unecessary overhead. Now we pass the whole configuration object and let the store extract the required values.
2017-10-31Replace uses of try!() macro with "?" operatorMatthias Beyer
2017-09-23Use error chain link functionality to remove link-conversion boilerplateMatthias Beyer
2017-09-15Query-path fixedMatthias Beyer
2017-09-15Add more debugging/tracing outputMatthias Beyer
2017-09-15Add test to test external linkingMatthias Beyer
2017-09-09Fix header locationsMatthias Beyer
Also change that the implementation uses toml_query::set instead of toml_query::insert. Inserting values creates intermediate tables, set doesn't. And we really want that convenience here, as the code is complex enough on its own.
2017-09-04Merge branch 'master' into libimagerror/integrationMatthias Beyer
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-04Remove dedicated result modules, use error chain generated Result typesMatthias Beyer
2017-09-03Remove "IntoError" trait, use error_chain functionalityMatthias Beyer
2017-09-03libimagentrylink: Rewrite error handlingMatthias Beyer
2017-08-31Merge branch 'libimagstore/remove-unused' into integrate-remove-unusedMatthias Beyer
The merge conflicts which were resolved may roll back some changes from the merged branch (unknowingly). These will be fixed in the next commits
2017-08-31Remove unused keyword "mut" where not neededMatthias Beyer
2017-08-28Change crates to use toml-query crateMatthias Beyer
2017-08-28Rewrite libimagentrylink::external::Link to be a traitMatthias Beyer
2017-08-27Reorganize code in subdirsMatthias Beyer