Skip to content

Commit def502c

Browse files
fix: avoid shell interpolation in publish workflow
1 parent 6a6b6fa commit def502c

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

.github/workflows/publish.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,12 +48,14 @@ jobs:
4848

4949
- name: Verify tag matches package version
5050
if: ${{ inputs.tag != '' }}
51+
env:
52+
INPUT_TAG: ${{ inputs.tag }}
5153
run: |
5254
set -euo pipefail
5355
package_version=$(node -p "require('./package.json').version")
5456
expected_tag="v${package_version}"
55-
if [ "${expected_tag}" != "${{ inputs.tag }}" ]; then
56-
echo "Input tag ${{ inputs.tag }} does not match package.json version ${package_version} (${expected_tag})"
57+
if [ "${expected_tag}" != "${INPUT_TAG}" ]; then
58+
echo "Input tag ${INPUT_TAG} does not match package.json version ${package_version} (${expected_tag})"
5759
exit 1
5860
fi
5961

0 commit comments

Comments
 (0)