-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: MustGetChildren works at the node level
Fixes #54 `(Must)GetChildren` operations where running at the unixfs layer of abstraction, which doesn't work when you're trying to list the children block of a file that is split into multiple nodes. Implement the operations at the ipld dag abstraction, meaning it's possible to list all the children blocks / CID in a file for example.
- Loading branch information
Showing
5 changed files
with
86 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
dir-54 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,11 @@ | ||
all: dag.car | ||
all: dag.car issue-54.car | ||
|
||
dag.car: | ||
npx ipfs-car pack --no-wrap ./dir --output ./dag.car | ||
|
||
issue-54.car: | ||
mkdir -p dir-54/sub1 | ||
echo "abc123" > dir-54/sub1/hello.txt | ||
mkdir -p dir-54/sub2 | ||
echo "xyz456" > dir-54/sub2/hello.txt | ||
ipfs dag export `ipfs add -Qr --chunker=size-5 dir-54` > ./issue-54.car |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters