void-packages/srcpkgs/github-cli/template

28 lines
779 B
Bash
Raw Normal View History

2020-02-14 11:27:39 +00:00
# Template file for 'github-cli'
pkgname=github-cli
2020-06-13 03:40:27 +00:00
version=0.10.0
2020-03-16 11:28:32 +00:00
revision=1
2020-02-14 11:27:39 +00:00
wrksrc="cli-${version}"
build_style=go
go_import_path="github.com/cli/cli/cmd/gh"
2020-02-14 14:37:37 +00:00
go_ldflags="-X github.com/cli/cli/command.Version=v${version}"
2020-02-14 11:27:39 +00: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-06-13 03:40:27 +00:00
checksum=5d7474a89cd0d284387f1b58dc8b1771ebae8fc83cfa2410b354435b295c07df
2020-02-14 11:27:39 +00:00
2020-02-14 14:37:37 +00: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 11:27:39 +00:00
post_install() {
vlicense LICENSE
}