Commit graph

108 commits

Author SHA1 Message Date
a796de322a Fix bug: Links were swapped 2016-10-15 11:36:25 +02:00
b64eae9654 Add multi-link test 2016-10-15 11:35:01 +02:00
6d31913321 Fix bug: We have to compare StoreId objects without their base 2016-10-15 11:24:42 +02:00
9c29bf19da Add debugging output 2016-10-15 11:24:14 +02:00
4e2bcf7d58 Add env-logger for test logging 2016-10-15 11:23:31 +02:00
36b77f4e38 Add test for linking+unlinking 2016-10-15 11:23:30 +02:00
d27c8ced34 Add first internal-linking test 2016-10-15 11:23:30 +02:00
02a2034d8b Fix usage of libimagentrylink interface 2016-10-14 13:27:06 +02:00
b70564f2ce Change InternalLinker to return iterator objects 2016-10-14 13:27:06 +02:00
e8ae4c0da7 Create symlinks to documentation files in libimag*/README.md 2016-10-13 12:04:36 +02:00
e30d774670 Move all libimag*/README.md to doc/src/05100-* 2016-10-13 12:04:36 +02:00
fbd6e790c7 Increment header levels in the README.md files of the libraries 2016-10-13 12:04:36 +02:00
2db79ada71 libimagentrylink: Add copyright notice to all files 2016-10-01 17:35:06 +02:00
40014051ec Bugfix: unique()ing the list of links
That should happen _after_ they are all in the same format.
This commit introduces overhead, as we clone() each string here for
comparison and that should clearly be fixed.

Though the bug-fix is more important at this point.
2016-09-06 15:30:26 +02:00
1dfe877cd9 Fix typo in is_external_link_storeid() helper fn 2016-09-05 18:52:42 +02:00
c23a11060f Add debug output 2016-09-05 18:51:35 +02:00
2956df81f1 Fix: We save the url at imag.content.url, not imag.content.uri 2016-09-05 18:49:12 +02:00
ccffeb91a2 Remove StoreId::is_in_collection(), add StoreId::local()
Having a ::is_in_collection() is a nice thing, though it is _way_ better
if we just give the user of the `StoreId` object access to the local
part of the ID.

Using this new function, one can do all the actions one might need on
the Path for the actual entry without nasty copying or such.

`StoreId::is_in_collection()` can be replaced by
`StoreId::local().starts_with()` and everything is fine, as we do not
have to move a `PathBuf` object into the function anymore.
2016-09-04 10:40:38 +02:00
4da331f990 Use new StoreId::is_in_collection() interface 2016-09-02 17:16:03 +02:00
46bf387fc3 Make internal linking only have store-relative links 2016-08-31 09:20:09 +02:00
3e4b0e4bb8 Rewrite internal link handling, returning Result<_> rather than Option<_> 2016-08-31 09:20:09 +02:00
d594b7c6a2 Reimplement libimagentrylink::external::is_external_link_storeid() using StoreId::is_in_collection() 2016-08-31 09:20:08 +02:00
82f08c6021 Remove version argument from module_entry_path_mod!() macro 2016-08-30 11:40:56 +02:00
522d73e6df Fix libimagentrylink::{error, internal}::* for new StoreId interface 2016-08-28 18:41:55 +02:00
aeb95b1e11 Fix libimagentrylink::external::* for new StoreId interface 2016-08-28 18:41:55 +02:00
Kai Sickeler
61feb5199c Upgrade toml dependency to 0.2 2016-08-06 17:21:31 +02:00
5935d43f09 Replace map(unwrap()) with fold() 2016-08-03 11:30:23 +02:00
41bf063a71 Replace map(unwrap()) with fold() 2016-08-03 11:29:38 +02:00
80491ff0b7 Replace map(unwrap()) with fold() 2016-08-03 11:27:26 +02:00
f46e8ac597 Replace unwrap with try!() 2016-08-03 11:27:25 +02:00
ca08f6d273 Export MapErrInto trait 2016-08-03 11:27:25 +02:00
6f07359416 Merge pull request #534 from matthiasbeyer/libimagentrylink/tmp-fix-external-link-checking
Temporary fix: Check whether an StoreId is an external link by str::c…
2016-07-15 11:21:44 +02:00
John Sirois
a1bf76ed79 Remove unused Link::retrieve helper. 2016-07-14 20:07:30 -06:00
3f2ababdb0 Add more robust version of is_external_link_storeid() helper function 2016-07-14 21:27:36 +02:00
1dd40ca8b9 Temporary fix: Check whether an StoreId is an external link by str::contains()
This is a temporary fix as long as we do not have a clear model how we
handle internal/external StoreId types
2016-07-14 21:04:46 +02:00
9337a14cdd Update all version strings: 0.1.0 -> 0.2.0 2016-07-12 11:51:20 +02:00
f542fafec2 Remove unneccessary block 2016-06-14 11:35:42 +02:00
8c7ca95af1 Remove if-else by map() 2016-06-14 11:35:42 +02:00
29be4029da Replace complex unwrapping with big match block 2016-06-11 06:50:58 +02:00
3e4b339615 Merge pull request #438 from matthiasbeyer/libimagentrylink/link-type-pub
Add missing keyword "pub" for Link type
2016-05-27 12:36:36 +02:00
98b39bbfa8 Use IntoError to have less noise in the error construction code 2016-05-27 10:38:35 +02:00
0f52900456 Add missing keyword "pub" for Link type 2016-05-26 22:08:27 +02:00
394b90f038 libimagentrylink: Refactor code with is_match!() macro 2016-05-23 21:43:20 +02:00
0e03998499 libimagentrylink: Add dependency: libimagutil 2016-05-23 21:43:14 +02:00
cf393b4bde libimagentrylink: use generate_error_module!() macro and reexport generated types 2016-05-19 20:32:23 +02:00
91f26220c6 libimagentrylink: Replace error module imports with macro helper 2016-05-19 18:22:03 +02:00
6850146e42 libimagentrylink: Replace error code with code generator macro 2016-05-17 00:26:36 +02:00
Andre Bogus
981707c9c9 more style adaptations
again following clippy
2016-05-13 22:27:53 +02:00
bf878c9245 Merge pull request #394 from matthiasbeyer/libimagentrylink/make-external-link-id-filter-helper-pub
Rename and make public: is_link_store_id() -> is_external_link_storeid()
2016-05-13 14:42:07 +02:00
86f3119dd5 Update dependency: url: 0.5.5 -> 1.1 2016-05-12 17:31:46 +02:00
7c9e52c25e Rename and make public: is_link_store_id() -> is_external_link_storeid() 2016-05-12 17:12:40 +02:00
abcbfd7f27 Update log: 0.3.* -> 0.3 2016-05-10 17:54:47 +02:00
b629d0b8f1 Merge pull request #367 from matthiasbeyer/unwrap_err
Unwrap err
2016-04-21 15:08:36 +02:00
e0988c5f76 Remove unneeded deref() call 2016-04-21 13:19:37 +02:00
5d2950b7df libimagentrylink: Replace .err().unwrap() with .unwrap_err() 2016-04-20 21:45:27 +02:00
2f34934fc8 libimaglink: Update itertools 2016-04-17 15:50:32 +02:00
b5fd085693 Fix names: libimaglink -> libimagentrylink 2016-04-17 12:22:13 +02:00
33aa56019f libimaglink -> libimagentrylink 2016-04-17 12:22:13 +02:00