Skip to content

CI jobs establishing a working baseline for the golang repos in this GitHub organization

Notifications You must be signed in to change notification settings

boinkor-net/ci-baseline-go

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

47 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Reusable baseline CI workflows for Go CI

The workflows in this repo all help drive the CI in this organization's Golang repos. There are a few workflows defined here that are reusable in github actions.

All these workflows expect to test a modules-enabled go repo and take some common arguments:

  • module_base: The directory containing the code base under test. Defaults to .
  • go_version: The version of go under test. If unset, this will use the version given in go.mod under module_base.

ci_baseline_go_tests.yml - Tests

This workflow runs go test against a module.

Example workflow:

jobs:
  tests:
    uses: "boinkor-net/ci-baseline-go/.github/workflows/ci_baseline_go_tests.yml@main"
    with:
      module_base: "cmd/hello-world"

ci_baseline_go_build.yml - Build

This workflow runs go build against a module. It has options:

  • subdir: The directory containing the main.go file resulting in the executable. Defaults to .

Example workflow:

jobs:
  build:
    uses: "./.github/workflows/ci_baseline_go_build.yml"
    with:
      module_base: "go/"
      subdir: cmd/hello-world

ci_baseline_go_lints.yml - Lints & formatting

This workflow runs golangci-lint and goimports against a module, as two separate / parallel jobs.

Example workflow:

  success_lints:
    uses: "./.github/workflows/ci_baseline_go_lints.yml"
    with:
      module_base: "cmd/hello-world"

About

CI jobs establishing a working baseline for the golang repos in this GitHub organization

Topics

Resources

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages