Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions crates/fetcher/fixtures/checksums.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"content.txt": "3dc7bc0209231cc61cb7d09c2efdfdf7aacb1f0b098db150780e980fa10d6b7a",
"content.tar.gz": "aa7d1aae79175b06c5529409d65f4794479c9b060381e059a8b6d1510fa2ae48"
}
Binary file added crates/fetcher/fixtures/content.tar.gz
Binary file not shown.
1 change: 1 addition & 0 deletions crates/fetcher/fixtures/content.txt

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions crates/fetcher/justfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@

# Create content.tar.gz from content.txt and generate checksums
fixtures:
./scripts/generate-fixtures.sh
29 changes: 29 additions & 0 deletions crates/fetcher/scripts/generate-fixtures.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
#!/bin/bash
set -e

# Navigate to the fetcher directory
cd "$(dirname "$0")/.."

echo "Creating content.tar.gz from content.txt..."
tar -czf fixtures/content.tar.gz -C fixtures content.txt

echo "Generating checksums..."

# Calculate SHA256 hashes
content_hash=$(shasum -a 256 fixtures/content.txt | cut -d' ' -f1)
archive_hash=$(shasum -a 256 fixtures/content.tar.gz | cut -d' ' -f1)

# Create JSON file with checksums
cat > fixtures/checksums.json <<EOF
{
"content.txt": "${content_hash}",
"content.tar.gz": "${archive_hash}"
}
EOF

echo "✓ Created fixtures/content.tar.gz"
echo "✓ Created fixtures/checksums.json"
echo ""
echo "Checksums:"
echo " content.txt: ${content_hash}"
echo " content.tar.gz: ${archive_hash}"
Loading