Initial commit

This commit is contained in:
Jean Lucas
2019-11-05 13:16:44 -05:00
commit 4498f5f339
3 changed files with 70 additions and 0 deletions

16
.SRCINFO Normal file
View File

@@ -0,0 +1,16 @@
pkgbase = stripe-cli
pkgdesc = CLI for Stripe
pkgver = 1.0.1
pkgrel = 1
url = https://stripe.com/docs/stripe-cli
arch = x86_64
license = Apache
makedepends = go
depends = glibc
source = stripe-cli-1.0.1.tar.gz::https://github.com/stripe/stripe-cli/archive/v1.0.1.tar.gz
source = reproducible-image-flags.patch
sha512sums = ef20c2fc9f29dbfaba4236de06df5ccf5fb686ed6c3a5513e32dc3e22820848d097aa590ae08e61f490ce21ce9a156a107bef8a74f4dd1f5e12f484d09e6b4e1
sha512sums = 4f5ff8662f5e4bce1ded88a055e652c41dd6492cda5aee74795752abf0e97cc269ec1fef84df2247f62809f0c8cc1a88dd12104e07090cc224bbc5ad46b33f37
pkgname = stripe-cli

38
PKGBUILD Normal file
View File

@@ -0,0 +1,38 @@
# Maintainer: Jean Lucas <jean@4ray.co>
pkgname=stripe-cli
pkgver=1.0.1
pkgrel=1
pkgdesc='CLI for Stripe'
arch=(x86_64)
url=https://stripe.com/docs/stripe-cli
license=(Apache)
depends=(glibc)
makedepends=(go)
source=(
$pkgname-$pkgver.tar.gz::https://github.com/stripe/stripe-cli/archive/v$pkgver.tar.gz
reproducible-image-flags.patch
)
sha512sums=('ef20c2fc9f29dbfaba4236de06df5ccf5fb686ed6c3a5513e32dc3e22820848d097aa590ae08e61f490ce21ce9a156a107bef8a74f4dd1f5e12f484d09e6b4e1'
'4f5ff8662f5e4bce1ded88a055e652c41dd6492cda5aee74795752abf0e97cc269ec1fef84df2247f62809f0c8cc1a88dd12104e07090cc224bbc5ad46b33f37')
prepare() {
cd $pkgname-$pkgver
# Add reproducible image flags
patch -Np0 < ../reproducible-image-flags.patch
make setup
}
build() {
cd $pkgname-$pkgver
make build
}
package() {
cd $pkgname-$pkgver
install -D stripe -t "$pkgdir"/usr/bin
install -Dm 644 README.md -t "$pkgdir"/usr/share/doc/$pkgname
cp -a docs "$pkgdir"/usr/share/doc/$pkgname
}

View File

@@ -0,0 +1,16 @@
--- Makefile 2019-11-05 13:19:33.405968540 -0500
+++ Makefile 2019-11-05 13:20:38.358685158 -0500
@@ -55,7 +55,12 @@
# Build a beta version of stripe
build:
go generate ./...
- go build -o stripe cmd/stripe/main.go
+ go build \
+ -buildmode pie \
+ -ldflags "-extldflags $(LDFLAGS)" \
+ -trimpath \
+ -o stripe \
+ cmd/stripe/main.go
.PHONY: build
build-dev: