mirror of
https://github.com/ivabus/pantry
synced 2024-11-25 18:05:07 +03:00
4b29c8af7f
closes #4048
30 lines
692 B
YAML
30 lines
692 B
YAML
distributable:
|
|
url: https://github.com/terraform-linters/tflint/archive/refs/tags/v{{ version }}.tar.gz
|
|
strip-components: 1
|
|
|
|
versions:
|
|
github: terraform-linters/tflint
|
|
strip: /v/
|
|
|
|
provides:
|
|
- bin/tflint
|
|
|
|
build:
|
|
dependencies:
|
|
go.dev: '*'
|
|
script: |
|
|
export GOPATH="$PWD/build"
|
|
mkdir -p dist
|
|
go build -v -ldflags="$LDFLAGS" -o dist/tflint
|
|
mkdir -p {{prefix}}/bin
|
|
mv dist/tflint {{prefix}}/bin/
|
|
env:
|
|
LDFLAGS: [-s, -w]
|
|
linux:
|
|
LDFLAGS: [-buildmode=pie]
|
|
|
|
test:
|
|
script: |
|
|
# tflint returns exitstatus: 0 (no issues), 2 (errors occured), 3 (no errors but issues found)
|
|
test "" = "$(tflint test.tf)"
|
|
tflint --version | grep {{version}}
|