void-packages/srcpkgs/github-cli/template

28 lines
778 B
Bash
Raw Normal View History

2020-02-14 12:27:39 +01:00
# Template file for 'github-cli'
pkgname=github-cli
2020-03-16 12:28:32 +01:00
version=0.6.1
revision=1
2020-02-14 12:27:39 +01:00
wrksrc="cli-${version}"
build_style=go
go_import_path="github.com/cli/cli/cmd/gh"
2020-02-14 15:37:37 +01:00
go_ldflags="-X github.com/cli/cli/command.Version=v${version}"
2020-02-14 12:27:39 +01:00
short_desc="GitHub CLI tool"
maintainer="shizonic <realtiaz@gmail.com>"
license="MIT"
homepage="https://cli.github.com"
changelog="https://github.com/cli/cli/releases"
distfiles="https://github.com/cli/cli/archive/v${version}.tar.gz"
2020-03-16 12:28:32 +01:00
checksum=237b18f9e3c82caa1cb06df3ca763ad7b32dab7e9a9a6f89afe7593bc31c3290
2020-02-14 12:27:39 +01:00
2020-02-14 15:37:37 +01:00
pre_build() {
local _date
if [ "$SOURCE_DATE_EPOCH" ]; then
_date="$(date --utc --date "@$SOURCE_DATE_EPOCH" "+%Y-%m-%d")"
go_ldflags="$go_ldflags -X github.com/cli/cli/command.BuildDate=${_date}"
fi
}
2020-02-14 12:27:39 +01:00
post_install() {
vlicense LICENSE
}