Skip to content

Commit d6b5c0e

Browse files
committed
Fix test-wordpress-prelease showing wrong version
We use the locked flake input, but the version being shown was from the current GitHub repo.
1 parent 9e40011 commit d6b5c0e

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

justfile

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,11 @@ test-live: _test-integration-live _test-aws
9898

9999
# Test against github:staticweb-io/wordpress-flake#prerelease
100100
test-wordpress-prerelease:
101-
@echo "Testing WordPress prerelease version" "$(nix build github:staticweb-io/wordpress-flake#prerelease --print-out-paths | sed 's/^[^-]*-[^-]*-//')"
101+
#!/usr/bin/env bash
102+
set -euo pipefail
103+
rev=$(nix flake metadata ./dev --json 2>/dev/null | jq -r '.locks.nodes["wordpress-flake"].locked.rev')
104+
version=$(nix eval "github:staticweb-io/wordpress-flake/$rev#prerelease.version" --raw 2>/dev/null)
105+
echo "Testing WordPress prerelease version $version"
102106
WORDPRESS_PACKAGE=prerelease nix flake check --impure ./dev
103107

104108
_update-composer-deps: && update-hashes

0 commit comments

Comments
 (0)