commit | 3a32958c2706f7048305d5a2e53633d7e37e97d0 | [log] [tgz] |
---|---|---|
author | Tobias Klauser <tklauser@distanz.ch> | Tue Jan 09 11:27:23 2024 +0100 |
committer | Zvonimir Pavlinovic <zpavlinovic@google.com> | Tue Feb 06 15:52:01 2024 +0000 |
tree | 0f3be2dae3f22e2d358a2ffc98b7d4036b6dea04 | |
parent | 7da72f730e37eeaad891fcff0a532d27ed737cd4 [diff] |
action.yml: update actions to latest versions Update actions/checkout v3 -> 4.1.1, see https://github.com/actions/checkout/compare/v3...v4.1.1 for changes. Update actions/setup-go v4.0.0 -> v5.0.0, see https://github.com/actions/setup-go/compare/v4.0.0...v5.0.0 for changes. Change-Id: I8b37eb73efb3d2103e421fbbc29f32b5df8c3037 Reviewed-on: https://go-review.googlesource.com/c/govulncheck-action/+/554895 Reviewed-by: Zvonimir Pavlinovic <zpavlinovic@google.com> Reviewed-by: Maceo Thompson <maceothompson@google.com> Run-TryBot: Zvonimir Pavlinovic <zpavlinovic@google.com> Commit-Queue: Zvonimir Pavlinovic <zpavlinovic@google.com> TryBot-Bypass: Zvonimir Pavlinovic <zpavlinovic@google.com> Commit-Queue: Tobias Klauser <tobias.klauser@gmail.com>
This repository holds the GitHub Action for govulncheck.
Govulncheck provides a low-noise, reliable way for Go users to learn about known vulnerabilities that may affect their dependencies. See details on Go's support for vulnerability management.
The govulncheck GitHub Action is currently experimental and is under active development.
To use the govulncheck GitHub Action add the following step to your workflow:
- id: govulncheck uses: golang/govulncheck-action@v1
By default the govulncheck Github Action will run with the latest version of Go and analyze all packages in the provided Go module. Assuming you have the latest Go version installed locally, this is equivalent to running the following on your command line:
$ govulncheck ./...
To specify a specific Go version, directory in which to run govulncheck, or package pattern, use the following syntax:
- id: govulncheck uses: golang/govulncheck-action@v1 with: go-version-input: <your-Go-version> go-package: <your-package-pattern>
For example, the code snippet below can be used to run govulncheck against a repository on every push:
on: [push] jobs: govulncheck_job: runs-on: ubuntu-latest name: Run govulncheck steps: - id: govulncheck uses: golang/govulncheck-action@v1 with: go-version-input: 1.20.6 go-package: ./...
govulncheck Github Action accepts several other optional inputs:
work-dir: directory in which to run govulncheck, default '.' repo-checkout: checkout the repository, default true check-latest: check for the latest Go version, default false go-version-file: go.mod or go.work file specifying Go version, default ''
The precedence for inputs go-version-input
, go-version-file
, and check-latest
specifying Go version is inherited from actions/setup-go.
When a vulnerability is found, an error will be displayed for that GitHub job with information about the vulnerability and how to fix it. For example:
Our canonical Git repository is located at https://go.googlesource.com/govulncheck-action. There is a mirror of the repository at https://github.com/golang/govulncheck-action. See https://go.dev/doc/contribute.html for details on how to contribute.
The main issue tracker for the time repository is located at
If you want to report a bug or have a feature suggestion, please file an issue at https://github.com/golang/go/issues, prefixed with govulncheck-action:
in the title.
Unless otherwise noted, the Go source files are distributed under the BSD-style license found in the LICENSE file.