Skip to content

pr#2 gs/cleanup-workflow by @drshriveer #12

pr#2 gs/cleanup-workflow by @drshriveer

pr#2 gs/cleanup-workflow by @drshriveer #12

name: PR Validation
run-name: pr#${{ github.event.number }} ${{ github.event.pull_request.head.ref }} by @${{ github.actor }}
on: pull_request
jobs:
detect-changes:
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: read
outputs:
changes: ${{ steps.filter.outputs.changes }}
steps:
- uses: actions/checkout@v3
- uses: dorny/paths-filter@v2
id: filter
with:
filters: |
changes:
- '**/*.go'
lint:
needs: detect-changes
runs-on: ubuntu-latest
permissions:
pull-requests: read
steps:
- uses: actions/checkout@v3
- uses: extractions/setup-just@v1
- uses: actions/setup-go@v4
with:
go-version-file: go.work
- run: just lint
test:
needs: detect-changes
runs-on: ubuntu-latest
permissions:
pull-requests: read
steps:
- uses: actions/checkout@v3
- uses: extractions/setup-just@v1
- uses: actions/setup-go@v4
with:
go-version-file: go.work
- run: just test