mirror of
https://github.com/ivabus/pantry
synced 2024-11-22 16:35:07 +03:00
8ec83543b8
closes #6068 closes #6069
41 lines
1 KiB
YAML
41 lines
1 KiB
YAML
distributable:
|
|
url: git+https://github.com/tursodatabase/turso-cli
|
|
ref: v{{version}}
|
|
|
|
versions:
|
|
github: tursodatabase/turso-cli/tags
|
|
strip: /^v/
|
|
|
|
provides:
|
|
- bin/turso
|
|
|
|
build:
|
|
script:
|
|
- go mod download
|
|
- go generate --tags=prod ./...
|
|
- go build $ARGS -ldflags="$LDFLAGS" ./cmd/turso
|
|
dependencies:
|
|
go.dev: ^1.20
|
|
env:
|
|
GO111MODULE: on
|
|
CGO_ENABLED: 0
|
|
ARGS:
|
|
- -v
|
|
- -trimpath
|
|
- -tags=prod
|
|
- -o "{{prefix}}"/bin/turso
|
|
LDFLAGS:
|
|
- -s
|
|
- -w
|
|
- -X main.debugMode=false
|
|
linux:
|
|
# or segmentation fault
|
|
# fix found here https://github.com/docker-library/golang/issues/402#issuecomment-982204575
|
|
LDFLAGS:
|
|
- -buildmode=pie
|
|
|
|
test:
|
|
- run: 'test "$(turso db locations 2>&1 || true)" = "Error: user not logged in, please login with turso auth login"'
|
|
if: <0.93.1
|
|
- run: 'test "$(turso db locations 2>&1 || true)" = "You are not logged in, please login with turso auth login before running other commands."'
|
|
if: '>=0.93.1'
|