Skip to content

Bump actions/cache from 2 to 4 #22

Bump actions/cache from 2 to 4

Bump actions/cache from 2 to 4 #22

name: Pull Request Checks
on:
pull_request:
permissions:
pull-requests: write
contents: write
jobs:
linting-and-testing:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup Go
uses: actions/setup-go@v2
with:
go-version: '1.19'
stable: true
- name: Cache Go Modules
uses: actions/cache@v4
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
- name: Tidy Modules
run: go mod tidy
- name: Build the provider
run: go build -o terraform-provider-abbey .
- name: Generate Docs
run: go generate ./...
- name: Run Unit Tests
run: make unit-test
dependabot:
name: 'Dependabot'
needs: [linting-and-testing]
runs-on: ubuntu-latest
if: ${{ github.actor == 'dependabot[bot]' && github.event_name == 'pull_request'}}
steps:
- name: Dependabot metadata
id: metadata
uses: dependabot/[email protected]
with:
github-token: '${{ secrets.GITHUB_TOKEN }}'
- name: Enable auto-merge for Dependabot PRs
run: gh pr merge --auto --merge "$PR_URL"
env:
PR_URL: ${{github.event.pull_request.html_url}}
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}