mastodon: adapt update script to new nix-prefetch-github

This commit is contained in:
Theodore Ni 2023-07-07 23:02:48 -07:00
parent f1836b946f
commit e8808ced29
No known key found for this signature in database
GPG Key ID: 48B67583BDDD4474
2 changed files with 3 additions and 3 deletions

View File

@ -4,7 +4,7 @@
owner = "mastodon";
repo = "mastodon";
rev = "v4.1.4";
sha256 = "8ULBO8IdwBzC5dgX3netTHbbRrODX4CropWZWtqWHZw=";
hash = "sha256-8ULBO8IdwBzC5dgX3netTHbbRrODX4CropWZWtqWHZw=";
};
in applyPatches {
inherit src;

View File

@ -76,7 +76,7 @@ trap cleanup EXIT
echo "Fetching source code $REVISION"
JSON=$(nix-prefetch-github "$OWNER" "$REPO" --rev "$REVISION" 2> $WORK_DIR/nix-prefetch-git.out)
SHA=$(echo "$JSON" | jq -r .sha256)
HASH=$(echo "$JSON" | jq -r .hash)
echo "Creating version.nix"
echo "\"$VERSION\"" | sed 's/^"v/"/' > version.nix
@ -88,7 +88,7 @@ cat > source.nix << EOF
owner = "mastodon";
repo = "mastodon";
rev = "$REVISION";
sha256 = "$SHA";
hash = "$HASH";
};
in applyPatches {
inherit src;