use a composite action
This commit is contained in:
27
.github/actions/setup-tools/action.yml
vendored
Normal file
27
.github/actions/setup-tools/action.yml
vendored
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
name: Setup tools
|
||||||
|
description: Installs all tools necessary for building and testing the project.
|
||||||
|
|
||||||
|
runs:
|
||||||
|
using: "composite"
|
||||||
|
steps:
|
||||||
|
- name: Setup mise
|
||||||
|
uses: jdx/mise-action@v2
|
||||||
|
|
||||||
|
- name: Go cache paths
|
||||||
|
id: go-cache-paths
|
||||||
|
shell: sh
|
||||||
|
run: |
|
||||||
|
echo "::set-output name=go-build::$(go env GOCACHE)"
|
||||||
|
echo "::set-output name=go-mod::$(go env GOMODCACHE)"
|
||||||
|
|
||||||
|
- name: Go build cache
|
||||||
|
uses: actions/cache@v2
|
||||||
|
with:
|
||||||
|
path: ${{ steps.go-cache-paths.outputs.go-build }}
|
||||||
|
key: ${{ runner.os }}-go-build-${{ hashFiles('**/go.sum') }}
|
||||||
|
|
||||||
|
- name: Go mod cache
|
||||||
|
uses: actions/cache@v2
|
||||||
|
with:
|
||||||
|
path: ${{ steps.go-cache-paths.outputs.go-mod }}
|
||||||
|
key: ${{ runner.os }}-go-mod-${{ hashFiles('**/go.sum') }}
|
||||||
20
.github/workflows/run-acceptance-tests.yml
vendored
20
.github/workflows/run-acceptance-tests.yml
vendored
@@ -71,9 +71,8 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
lfs: true
|
lfs: true
|
||||||
ref: ${{ env.PR_COMMIT_SHA }}
|
ref: ${{ env.PR_COMMIT_SHA }}
|
||||||
- uses: jdx/mise-action@v2
|
- name: Setup tools
|
||||||
with:
|
uses: ./.github/actions/setup-tools
|
||||||
experimental: true # [default: false] enable experimental features
|
|
||||||
- id: version
|
- id: version
|
||||||
name: Set Provider Version
|
name: Set Provider Version
|
||||||
uses: pulumi/provider-version-action@v1
|
uses: pulumi/provider-version-action@v1
|
||||||
@@ -165,7 +164,8 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
lfs: true
|
lfs: true
|
||||||
ref: ${{ env.PR_COMMIT_SHA }}
|
ref: ${{ env.PR_COMMIT_SHA }}
|
||||||
- uses: jdx/mise-action@v2
|
- name: Setup tools
|
||||||
|
uses: ./.github/actions/setup-tools
|
||||||
- id: version
|
- id: version
|
||||||
name: Set Provider Version
|
name: Set Provider Version
|
||||||
uses: pulumi/provider-version-action@v1
|
uses: pulumi/provider-version-action@v1
|
||||||
@@ -237,9 +237,8 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
lfs: true
|
lfs: true
|
||||||
ref: ${{ env.PR_COMMIT_SHA }}
|
ref: ${{ env.PR_COMMIT_SHA }}
|
||||||
- uses: jdx/mise-action@v2
|
- name: Setup tools
|
||||||
with:
|
uses: ./.github/actions/setup-tools
|
||||||
experimental: true # [default: false] enable experimental features
|
|
||||||
- id: version
|
- id: version
|
||||||
name: Set Provider Version
|
name: Set Provider Version
|
||||||
uses: pulumi/provider-version-action@v1
|
uses: pulumi/provider-version-action@v1
|
||||||
@@ -335,9 +334,6 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
lfs: true
|
lfs: true
|
||||||
ref: ${{ env.PR_COMMIT_SHA }}
|
ref: ${{ env.PR_COMMIT_SHA }}
|
||||||
- uses: jdx/mise-action@v2
|
- name: Setup tools
|
||||||
with:
|
uses: ./.github/actions/setup-tools
|
||||||
experimental: true # [default: false] enable experimental features
|
|
||||||
env:
|
|
||||||
MISE_TRACE: "1"
|
|
||||||
- run: make lint
|
- run: make lint
|
||||||
|
|||||||
Reference in New Issue
Block a user