zaibon / go-buildinfo

Action to help in populating buildinfo for Go.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

go-buildinfo

This is a sibling to https://github.com/daaku/buildinfo. When used along with that, it makes it easy to embed build information into a Go binary that is built using GitHub Actions.

First uses the action, the pass the BI_LDFLAGS env variable as your -ldflags argument to go build.

- uses: daaku/go-buildinfo@v1.0.2
- name: Build
  run: go build -trimpath -ldflags="$BI_LDFLAGS" ./...

Optionally set release_version for greater control. By default it will use the tag if present, or action run number.

About

Action to help in populating buildinfo for Go.

License:MIT License


Languages

Language:TypeScript 70.3%Language:JavaScript 24.3%Language:Go 5.5%