You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .github/workflows/release.yml
+14-1Lines changed: 14 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -45,8 +45,21 @@ jobs:
45
45
${{ runner.os }}-buildx-
46
46
- name: Get version from semantic-release
47
47
id: version
48
+
env:
49
+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
48
50
run: |
49
-
VERSION=$(npx semantic-release --dry-run | grep -oP 'The next release version is \K[0-9]+\.[0-9]+\.[0-9]+')
51
+
set -euo pipefail
52
+
53
+
echo "Running semantic-release dry-run to extract next version..."
54
+
VERSION=$(npx semantic-release --no-ci --dry-run 2>&1 | tee semantic-output.log | grep -oP 'The next release version is \K[0-9]+\.[0-9]+\.[0-9]+' || true)
55
+
56
+
if [ -z "$VERSION" ]; then
57
+
echo "❌ Failed to extract VERSION from semantic-release output:"
0 commit comments