Fix syntax for actionlint workflow (#903)

* Fix syntax for actionlint workflow
* Move .github/workflows/setup-test-tools/ -> .github/actions/setup-test-tools/
* Fix reported actionlint failures
This commit is contained in:
Tom Proctor 2023-05-31 12:27:18 +01:00 committed by GitHub
parent da34c6c986
commit a56c27c892
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 6 additions and 8 deletions

View file

@ -10,7 +10,7 @@ jobs:
steps: steps:
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2
- name: Setup test tools - name: Setup test tools
uses: ./.github/workflows/setup-test-tools uses: ./.github/actions/setup-test-tools
- name: Create K8s Kind Cluster - name: Create K8s Kind Cluster
uses: helm/kind-action@fa81e57adff234b2908110485695db0f181f3c67 # v1.7.0 uses: helm/kind-action@fa81e57adff234b2908110485695db0f181f3c67 # v1.7.0
with: with:

View file

@ -11,6 +11,4 @@ permissions:
contents: read contents: read
jobs: jobs:
actionlint: actionlint:
runs-on: ubuntu-latest uses: hashicorp/vault-workflows-common/.github/workflows/actionlint.yaml@main
steps:
- uses: hashicorp/vault-workflows-common/.github/workflows/actionlint.yaml@main

View file

@ -5,7 +5,7 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2
- uses: ./.github/workflows/setup-test-tools - uses: ./.github/actions/setup-test-tools
- run: bats --tap --timing ./test/unit - run: bats --tap --timing ./test/unit
chart-verifier: chart-verifier:
runs-on: ubuntu-latest runs-on: ubuntu-latest
@ -14,11 +14,11 @@ jobs:
steps: steps:
- uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2 - uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2
- name: Setup test tools - name: Setup test tools
uses: ./.github/workflows/setup-test-tools uses: ./.github/actions/setup-test-tools
- uses: actions/setup-go@4d34df0c2316fe8122ab82dc22947d607c0c91f9 # v4.0.0 - uses: actions/setup-go@4d34df0c2316fe8122ab82dc22947d607c0c91f9 # v4.0.0
with: with:
go-version: '1.19.2' go-version: '1.19.2'
- run: go install github.com/redhat-certification/chart-verifier@${CHART_VERIFIER_VERSION} - run: go install "github.com/redhat-certification/chart-verifier@${CHART_VERIFIER_VERSION}"
- run: bats --tap --timing ./test/chart - run: bats --tap --timing ./test/chart
permissions: permissions:
contents: read contents: read

View file

@ -15,7 +15,7 @@ jobs:
- name: verify Chart version matches tag version - name: verify Chart version matches tag version
run: |- run: |-
export TAG=${{ github.ref_name }} export TAG=${{ github.ref_name }}
git_tag=$(echo "${TAG#v}") git_tag="${TAG#v}"
chart_tag=$(yq r Chart.yaml version) chart_tag=$(yq r Chart.yaml version)
if [ "${git_tag}" != "${chart_tag}" ]; then if [ "${git_tag}" != "${chart_tag}" ]; then
echo "chart version (${chart_tag}) did not match git version (${git_tag})" echo "chart version (${chart_tag}) did not match git version (${git_tag})"