Skip to content

chore(deps): pin dependencies - autoclosed #21

chore(deps): pin dependencies - autoclosed

chore(deps): pin dependencies - autoclosed #21

Workflow file for this run

# name of the action
name: validate
# trigger on pull_request or push events
on:
pull_request:
push:
# pipeline to execute
jobs:
validate:
runs-on: ubuntu-latest
container:
image: golang:1.22@sha256:f43c6f049f04cbbaeb28f0aad3eea15274a7d0a7899a617d0037aec48d7ab010
steps:
- name: clone
uses: actions/checkout@ee0669bd1cc54295c223e0bb666b733df41de1c5 # v2
- name: validate
run: |
# Check that go mod tidy produces a zero diff; clean up any changes afterwards.
go mod tidy && git diff --exit-code; code=$?; git checkout -- .; (exit $code)
# Check that go vet ./... produces a zero diff; clean up any changes afterwards.
go vet ./... && git diff --exit-code; code=$?; git checkout -- .; (exit $code)
# Check that go fmt ./... produces a zero diff; clean up any changes afterwards.
go fmt ./... && git diff --exit-code; code=$?; git checkout -- .; (exit $code)
# Check that go fix ./... produces a zero diff; clean up any changes afterwards.
go fix ./... && git diff --exit-code; code=$?; git checkout -- .; (exit $code)