add(age, age-keygen) (#4099)

* add(age, age-keygen)

* buildmode=pie

* i always mess up yaml with the web editor

---------

Co-authored-by: Jacob Heider <jacob@pkgx.dev>
This commit is contained in:
Markus Zoppelt 2023-11-17 21:09:39 +01:00 committed by GitHub
parent 60d3d1dfec
commit bd2da12fbb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -0,0 +1,33 @@
distributable:
url: https://github.com/FiloSottile/age/archive/refs/tags/v{{ version }}.tar.gz
strip-components: 1
display-name: age
versions:
github: FiloSottile/age
provides:
- bin/age
- bin/age-keygen
build:
script: |
mkdir -p build/age
go build -o "build/age" -ldflags "$LDFLAGS" -trimpath ./cmd/...
mkdir -p "{{ prefix }}"/bin
mv build/age/age "{{ prefix }}"/bin
mv build/age/age-keygen "{{ prefix }}"/bin
env:
LDFLAGS:
- -X main.Version="{{version}}"
linux:
LDFLAGS:
- -buildmode=pie
dependencies:
go.dev: ^1.19
test:
age --version
age-keygen --version