fix(grype)

closes #5068
This commit is contained in:
Jacob Heider 2024-01-31 13:17:07 -05:00 committed by Jacob Heider
parent 3ab24891c4
commit d4bb4941dd

View file

@ -1,11 +1,13 @@
distributable: distributable:
url: https://github.com/anchore/grype/archive/v{{version}}.tar.gz url: https://github.com/anchore/grype/archive/v{{version}}.tar.gz
strip-components: 1 strip-components: 1
versions: versions:
github: anchore/grype github: anchore/grype
build: build:
dependencies: dependencies:
go.dev: '*' go.dev: ^1.21
script: script:
- go build $GO_ARGS -ldflags="$LD_FLAGS" ./cmd/grype - go build $GO_ARGS -ldflags="$LD_FLAGS" ./cmd/grype
env: env:
@ -13,11 +15,16 @@ build:
- -s -w - -s -w
- -X main.version={{version}} - -X main.version={{version}}
- -X main.gitCommit=pkgx - -X main.gitCommit=pkgx
linux:
LD_FLAGS:
- -buildmode=pie
GO_ARGS: GO_ARGS:
- -trimpath - -trimpath
- -o="{{prefix}}/bin/grype" - -o="{{prefix}}/bin/grype"
provides: provides:
- bin/grype - bin/grype
test: test:
script: - grype --version
- grype --version | grep {{version}} - grype --version | grep {{version}}