Commit Graph

265 Commits

Author SHA1 Message Date
Joonas Koivunen
8b7011f638 chore(unixfs): clippies
this includes a change on making `unixfs::InvalidCidInLink` properly
`#[non_exhaustive]` instead of using the hidden field trick. it probably
isn't a breaking change, but then again requires a more recent rustc,
which sort of makes it a breaking change.
2022-01-31 12:10:00 +02:00
Krzysztof Lis
136496f7de refactor(swarm): simplify usage of multiaddr after libp2p upgrade to 0.39
Get rid of eq_greedy.
2021-08-23 13:31:20 +02:00
Krzysztof Lis
414ccf5cbd chore: upgrade some of the other deps, fix tests 2021-08-18 14:58:33 +02:00
Krzysztof Lis
b713f86819 chore(deps): hash_hasher doesn't have any features 2021-08-04 15:01:03 +02:00
Krzysztof Lis
3254c05d44 perf: Use hash_hasher in hashmaps/sets where the key is a Cid/Multihash
Referenced-issues #258
2021-08-04 15:01:03 +02:00
Mirko von Leipzig
5e1427c563 chore(clippy): prefer Path to PathBuf 2021-08-02 14:49:09 +02:00
Mirko von Leipzig
b732b7ab24 chore(clippy): redundant borrows 2021-08-02 14:49:09 +02:00
Joonas Koivunen
6eea46d7b7 doc: enhance Walker docs for linking
not sure if the wording is at all correct but this is at least a bit
more correct.
2021-01-04 10:55:07 +02:00
Joonas Koivunen
5801e006b2 doc: document panic with Walker::pending_links 2021-01-04 10:55:07 +02:00
Joonas Koivunen
7c9fae92c2 refactor: remove extra lifetime 2021-01-04 10:55:07 +02:00
Joonas Koivunen
911fab510a chore: clippy push_str with single char str 2020-12-08 14:53:32 +02:00
Niklas Long
c112743d6e cleanup and document benchmark 2020-10-14 16:39:52 +02:00
Niklas Long
9fe8ef6f58 add unixfs benchmark 2020-10-13 16:05:46 +02:00
Caio
ffd9e80be0 Typos 2020-10-06 15:40:57 -03:00
Joonas Koivunen
435d146ad1 chore: prepare CHANGELOGs for Next version 2020-09-24 11:35:46 +03:00
Joonas Koivunen
9b8d9ab68e chore: bump ipfs-unixfs version to 0.2.0 2020-09-23 16:11:23 +03:00
Joonas Koivunen
cbbccf58b5 chore: update unixfs/CHANGELOG.md 2020-09-23 16:11:23 +03:00
Caio
6ee9299422 Remove Default full path 2020-09-08 09:21:32 -03:00
Joonas Koivunen
e2efa5236a doc: suggestions from code review
Co-authored-by: ljedrz <ljedrz@users.noreply.github.com>
2020-08-25 14:07:29 +03:00
Joonas Koivunen
bc2cdc873a fix: ungenericify subslice_to_range, add warnings 2020-08-25 12:36:37 +03:00
Joonas Koivunen
44f30ac8b5 doc(unixfs): correct doc for ResolveError::UnexpectedType 2020-08-25 12:36:37 +03:00
Joonas Koivunen
3fa42e1f2e add: dagpb NodeData wrapper
if I am correct, this is not strictly needed but I wrote it while being
stuck on other things. this allows "reusing" the existing
bitswap::Blocks Box<[u8]> allocation and serving a subslice of it as the
node data, per deserialization.
2020-08-25 12:35:42 +03:00
Caio
5e86951115 Rustfmt 2020-08-24 12:54:57 -03:00
Caio
3b109a1ffe Use alloc crate where is applicable within unixfs 2020-08-24 12:54:40 -03:00
Caio
2f395906bc Use core crate where is applicable within unixfs 2020-08-23 12:07:16 -03:00
Caio
ffde6a3d03 Clippy 2020-08-17 12:27:49 -03:00
Joonas Koivunen
da316aec33
doc: suggestions from code review
Co-authored-by: ljedrz <ljedrz@users.noreply.github.com>
2020-08-14 16:29:16 +03:00
Joonas Koivunen
42e1d5309d doc: minor touchups
tried to look into how should the links be done today but I guess there
are still some nightly shenanigans so cannot really preview before
publishing.
2020-08-14 16:00:29 +03:00
Joonas Koivunen
3176976ba2 doc: revisit file.rs docs 2020-08-14 15:51:35 +03:00
Joonas Koivunen
b671a767f1 doc: unify top-level mod summaries 2020-08-14 15:49:20 +03:00
Joonas Koivunen
b495c57a1f chore: update README.md 2020-08-14 15:47:20 +03:00
Joonas Koivunen
2a68d04a81 chore: use correct PR for unixfs symlinks 2020-08-14 15:23:03 +03:00
Joonas Koivunen
1e79d9e81d chore: bump unixfs 0.1.0 2020-08-14 15:18:16 +03:00
Joonas Koivunen
472471f282 chore: update CHANGELOG 2020-08-14 15:18:16 +03:00
Joonas Koivunen
a6728b58c7 fix: use latest walker api 2020-08-14 14:54:50 +03:00
Joonas Koivunen
3dd7caf01c add: quite verbose test cases around symlinks 2020-08-14 14:40:21 +03:00
Joonas Koivunen
d505fdf284 feat: serialization of symlink blocks 2020-08-14 14:40:21 +03:00
bors[bot]
d2760bb4d5
Merge #294
294: Remove Walker indirection r=koivunej a=c410-f3r

Fixes #200.

By using mutable references instead of taking ownership, the following is now possible:

```rust
ContinuedWalk::Symlink(bytes, _, path, metadata) => {
  ...
}

// Instead of

ContinuedWalk::Symlink(bytes, item) => {
  if let Entry::Metadata(metadata_entry) = item.as_entry() {
    ...
  }
}
```

Co-authored-by: Caio <c410.f3r@gmail.com>
Co-authored-by: Joonas Koivunen <joonas@equilibrium.co>
2020-08-14 11:36:11 +00:00
ljedrz
e2a2b5abcb chore: future(/feature)-proof the criterion dep
Signed-off-by: ljedrz <ljedrz@gmail.com>
2020-08-14 11:30:20 +02:00
Joonas Koivunen
d2ea05f64a doc: update comments regarding buckets 2020-08-14 10:32:10 +03:00
Joonas Koivunen
e129973e03 refactor: restore custom fmt::Debug for InnerEntry
this needs to follow Cid as we don't really need the Cid's fmt::Debug
impl.
2020-08-14 10:32:10 +03:00
Joonas Koivunen
59deeca4ae doc: remove completed FIXME 2020-08-14 10:26:33 +03:00
Joonas Koivunen
7c50ce435a doc: update comments 2020-08-14 10:23:03 +03:00
Joonas Koivunen
e300e149dc refactor: remove unnecessary lifetime 2020-08-14 10:19:56 +03:00
Joonas Koivunen
a94536b882 refactor: revert unneeded change 2020-08-14 10:19:56 +03:00
Joonas Koivunen
9f979effcb refactor: revert unnecessary match changes 2020-08-14 10:19:53 +03:00
Joonas Koivunen
a5e3bbbb98 refactor: reorder InnerEntry, Kind 2020-08-14 10:19:53 +03:00
Joonas Koivunen
4ba9a74b7a refactor: revert unnecessary visibility 2020-08-14 10:19:49 +03:00
Joonas Koivunen
e5e43e4322 refactor: reorder back link conversions 2020-08-14 09:40:08 +03:00
Joonas Koivunen
9f3ab40dcd refactor: reorder back ContinuedWalk, FileSegment, Error 2020-08-14 09:39:18 +03:00