Skip to content

Instantly share code, notes, and snippets.

@earthboundkid
Created March 11, 2025 16:14
Show Gist options
  • Save earthboundkid/d37e06008241af463c006774d3237dd4 to your computer and use it in GitHub Desktop.
Save earthboundkid/d37e06008241af463c006774d3237dd4 to your computer and use it in GitHub Desktop.
GitHub action boilerplate
name: Go
on: [push, pull_request]
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: "stable"
- name: Download modules
run: go mod download
- name: Check go.mod
run: go mod tidy -diff
- name: Test
run: go test -race -v -coverprofile=profile.cov ./...
- uses: shogo82148/actions-goveralls@v1
with:
path-to-profile: profile.cov
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment