fix: pin 6 actions to commit SHA, extract 1 expression to env var

This commit is contained in:
dagecko
2026-03-28 15:57:55 -04:00
parent f07797533d
commit 28a1fbc3f2
4 changed files with 9 additions and 7 deletions

View File

@@ -44,7 +44,7 @@ jobs:
# Package manager setup # Package manager setup
- name: Setup pnpm - name: Setup pnpm
if: matrix.pm == 'pnpm' if: matrix.pm == 'pnpm'
uses: pnpm/action-setup@v4 uses: pnpm/action-setup@fc06bc1257f339d1d5d8b3a19a8cae5388b55320 # v4
with: with:
version: latest version: latest
@@ -57,7 +57,7 @@ jobs:
- name: Setup Bun - name: Setup Bun
if: matrix.pm == 'bun' if: matrix.pm == 'bun'
uses: oven-sh/setup-bun@v2 uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2
# Cache configuration # Cache configuration
- name: Get npm cache directory - name: Get npm cache directory

View File

@@ -20,11 +20,13 @@ jobs:
- name: Validate version tag - name: Validate version tag
run: | run: |
if ! [[ "${{ github.ref_name }}" =~ ^v[0-9]+\.[0-9]+\.[0-9]+$ ]]; then if ! [[ "${REF_NAME}" =~ ^v[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
echo "Invalid version tag format. Expected vX.Y.Z" echo "Invalid version tag format. Expected vX.Y.Z"
exit 1 exit 1
fi fi
env:
REF_NAME: ${{ github.ref_name }}
- name: Verify plugin.json version matches tag - name: Verify plugin.json version matches tag
env: env:
TAG_NAME: ${{ github.ref_name }} TAG_NAME: ${{ github.ref_name }}
@@ -61,7 +63,7 @@ jobs:
EOF EOF
- name: Create GitHub Release - name: Create GitHub Release
uses: softprops/action-gh-release@v2 uses: softprops/action-gh-release@153bb8e04406b158c6c84fc1615b65b24149a1fe # v2
with: with:
body_path: release_body.md body_path: release_body.md
generate_release_notes: true generate_release_notes: true

View File

@@ -49,7 +49,7 @@ jobs:
EOF EOF
- name: Create GitHub Release - name: Create GitHub Release
uses: softprops/action-gh-release@v2 uses: softprops/action-gh-release@153bb8e04406b158c6c84fc1615b65b24149a1fe # v2
with: with:
tag_name: ${{ inputs.tag }} tag_name: ${{ inputs.tag }}
body_path: release_body.md body_path: release_body.md

View File

@@ -36,7 +36,7 @@ jobs:
- name: Setup pnpm - name: Setup pnpm
if: inputs.package-manager == 'pnpm' if: inputs.package-manager == 'pnpm'
uses: pnpm/action-setup@v4 uses: pnpm/action-setup@fc06bc1257f339d1d5d8b3a19a8cae5388b55320 # v4
with: with:
version: latest version: latest
@@ -49,7 +49,7 @@ jobs:
- name: Setup Bun - name: Setup Bun
if: inputs.package-manager == 'bun' if: inputs.package-manager == 'bun'
uses: oven-sh/setup-bun@v2 uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2
- name: Get npm cache directory - name: Get npm cache directory
if: inputs.package-manager == 'npm' if: inputs.package-manager == 'npm'