chore(actions): pass gh token when needed and add bash flags

This commit is contained in:
Erica Marigold 2025-02-14 01:31:01 +05:30
parent ff69d687b1
commit 4831384c16
Signed by: DevComp
SSH key fingerprint: SHA256:jD3oMT4WL3WHPJQbrjC3l5feNCnkv7ndW8nYaHX5wFw

View file

@ -36,8 +36,13 @@ jobs:
- name: Parse stylua semver range into version
id: stylua
run: |
#!/bin/bash
set -euo pipefail
range="${{ steps.get_semver_range.outputs.value }}"
echo "version=$(gh api /repos/JohnnyMorganz/StyLua/tags --jq '.[] | .name' | xargs semver -r "$range" | tail -n 1)" >> $GITHUB_OUTPUT
env:
GH_TOKEN: ${{ github.token }}
- name: Install stylua
uses: JohnnyMorganz/stylua-action@v4
@ -78,8 +83,13 @@ jobs:
- name: Parse luau-lsp semver range into version
id: luau-lsp
run: |
#!/bin/bash
set -euo pipefail
range="${{ steps.get_semver_range.outputs.value }}"
echo "version=$(gh api /repos/JohnnyMorganz/luau-lsp/tags --jq '.[] | .name' | xargs semver -r "$range" | tail -n 1)" >> $GITHUB_OUTPUT
env:
GH_TOKEN: ${{ github.token }}
- name: Install luau-lsp
shell: bash