Skip to content

Merge pull request #18 from golingon/dependabot/go_modules/gomod-0bb5… #17

Merge pull request #18 from golingon/dependabot/go_modules/gomod-0bb5…

Merge pull request #18 from golingon/dependabot/go_modules/gomod-0bb5… #17

Workflow file for this run

name: main
on:
push:
branches:
- main
concurrency:
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#example-only-cancel-in-progress-jobs-or-runs-for-the-current-workflow
group: ${{ github.workflow }}-${{ github.ref }} # To only cancel in-progress runs of the same workflow
cancel-in-progress: true
permissions: # added using https://github.com/step-security/secure-workflows
contents: read
jobs:
test:
permissions:
contents: read # for actions/checkout to fetch code
pull-requests: read # for golangci/golangci-lint-action to fetch pull requests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@1d96c772d19495a3b5c517cd2bc0cb401ea0529f # v4.0.0
with:
fetch-depth: 1
- uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5.0.0
with:
go-version-file: './go.mod'
check-latest: true
cache-dependency-path: ./go.mod
- name: go test
run: go test -v ./pkg/...
- name: git diff
run: git --no-pager diff HEAD --exit-code
- name: golangci-lint
uses: golangci/golangci-lint-action@3cfe3a4abbb849e10058ce4af15d205b6da42804 # v4.0.0
with:
args: -v --timeout 1m