forked from gentoo/gentoo
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
app-admin/doctl: version bump to 1.68, EAPI 8
Package-Manager: Portage-3.0.28, Repoman-3.0.3 Signed-off-by: Vladimir Pavljuchenkov <[email protected]> Closes: gentoo#23611 Signed-off-by: Florian Schmaus <[email protected]>
- Loading branch information
Showing
2 changed files
with
44 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
DIST doctl-1.57.0.tar.gz 5195498 BLAKE2B 17273e9f8f63464aa2ba6c6d48dfabd78b0bdeb7156dc315d1970fb0052710c7a4b37f1d5e2a7a60211f2ab166c0926de438959d853639a8c329ec39b3ee0577 SHA512 0c868c5732a48367a93bf2b884689dbd917ba6690c82516495862546bc31d58d44aab192bd3b3543f951e9fa9b7289e99fbdf828c017af68496b84f1585a5f6b | ||
DIST doctl-1.68.0.tar.gz 5514572 BLAKE2B e44be00e1b7451e84d3d6dc5a19dc04fcb5dab2c8a5c1923c0c0f99058a1938f9567d63681989e869341957586cdf549842cd45ca82503007039ae989664e8ff SHA512 d81799c227c071793af74f78e54d8348782caf158b28e0a12b92adf17b6c78c787a82abbdf3aa340a960f26c929b00f38015725e6e629aad7615096270d19c10 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# Copyright 1999-2022 Gentoo Authors | ||
# Distributed under the terms of the GNU General Public License v2 | ||
|
||
EAPI=8 | ||
|
||
inherit bash-completion-r1 go-module | ||
|
||
DESCRIPTION="A command line tool for DigitalOcean services" | ||
HOMEPAGE="https://github.com/digitalocean/doctl" | ||
SRC_URI="https://github.com/digitalocean/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" | ||
|
||
LICENSE="Apache-2.0 MIT BSD BSD-2 ISC MPL-2.0" | ||
SLOT="0" | ||
KEYWORDS="~amd64 ~x86" | ||
|
||
src_compile() { | ||
LDFLAGS="-X github.com/digitalocean/doctl.Major=$(ver_cut 1) | ||
-X github.com/digitalocean/doctl.Minor=$(ver_cut 2) | ||
-X github.com/digitalocean/doctl.Patch=$(ver_cut 3-) | ||
-X github.com/digitalocean/doctl.Label=release" | ||
GOFLAGS="-v -x -mod=vendor" \ | ||
go build -ldflags "$LDFLAGS" ./cmd/... || die "build failed" | ||
|
||
./doctl completion bash > doctl.bash || die "completion for bash failed" | ||
./doctl completion zsh > doctl.zsh || die "completion for sh failed" | ||
./doctl completion fish > doctl.fish || die "completion for fish failed" | ||
} | ||
|
||
src_test() { | ||
GOFLAGS="-v -x -mod=vendor" \ | ||
go test -work ./do/... ./pkg/... . || die "test failed" | ||
} | ||
|
||
src_install() { | ||
einstalldocs | ||
dobin doctl | ||
|
||
newbashcomp doctl.bash doctl | ||
insinto /usr/share/zsh/site-functions | ||
newins doctl.zsh _doctl | ||
insinto /usr/share/fish/completion | ||
newins doctl.fish doctl | ||
} |