mirror of
https://github.com/sipeed/picoclaw.git
synced 2026-05-25 16:00:35 +00:00
6e1fab80e2
* fix(release): drop stale launcher tui goreleaser target * * delete unused file
216 lines
5.6 KiB
YAML
216 lines
5.6 KiB
YAML
# yaml-language-server: $schema=https://goreleaser.com/static/schema.json
|
|
# vim: set ts=2 sw=2 tw=0 fo=cnqoj
|
|
version: 2
|
|
|
|
git:
|
|
ignore_tags:
|
|
- nightly
|
|
- ".*-nightly.*"
|
|
|
|
before:
|
|
hooks:
|
|
- go generate ./...
|
|
- sh -c 'cd web/frontend && CI=true pnpm install --frozen-lockfile && pnpm build:backend'
|
|
- sh -c 'GOBIN="$(go env GOPATH)/bin"; mkdir -p "$GOBIN"; go install github.com/tc-hib/go-winres@v0.3.3 && "$GOBIN/go-winres" make --in web/backend/winres/winres.json --out web/backend/rsrc --product-version={{ .Version }} --file-version={{ .Version }}'
|
|
- sh -c 'if [ "${INCLUDE_ANDROID_BUNDLE:-}" = "true" ]; then make build-android-bundle; fi'
|
|
|
|
builds:
|
|
- id: picoclaw
|
|
env:
|
|
- CGO_ENABLED=0
|
|
tags:
|
|
- goolm
|
|
- stdjson
|
|
ldflags:
|
|
- -s -w
|
|
- -X github.com/sipeed/picoclaw/pkg/config.Version={{ .Version }}
|
|
- -X github.com/sipeed/picoclaw/pkg/config.GitCommit={{ .ShortCommit }}
|
|
- -X github.com/sipeed/picoclaw/pkg/config.BuildTime={{ .Date }}
|
|
- -X github.com/sipeed/picoclaw/pkg/config.GoVersion={{ with index .Env "GOVERSION" }}{{ . }}{{ else }}unknown{{ end }}
|
|
goos:
|
|
- linux
|
|
- windows
|
|
- darwin
|
|
- freebsd
|
|
- netbsd
|
|
goarch:
|
|
- amd64
|
|
- arm64
|
|
- riscv64
|
|
- loong64
|
|
- arm
|
|
- s390x
|
|
- mipsle
|
|
goarm:
|
|
- "6"
|
|
- "7"
|
|
gomips:
|
|
- softfloat
|
|
main: ./cmd/picoclaw
|
|
ignore:
|
|
- goos: windows
|
|
goarch: arm
|
|
- goos: netbsd
|
|
goarch: s390x
|
|
- goos: netbsd
|
|
goarch: mips64
|
|
- goos: netbsd
|
|
goarch: arm
|
|
|
|
- id: picoclaw-launcher
|
|
binary: picoclaw-launcher
|
|
env:
|
|
- CGO_ENABLED=0
|
|
tags:
|
|
- goolm
|
|
- stdjson
|
|
ldflags:
|
|
- -s -w
|
|
- -X github.com/sipeed/picoclaw/pkg/config.Version={{ .Version }}
|
|
- -X github.com/sipeed/picoclaw/pkg/config.GitCommit={{ .ShortCommit }}
|
|
- -X github.com/sipeed/picoclaw/pkg/config.BuildTime={{ .Date }}
|
|
- -X github.com/sipeed/picoclaw/pkg/config.GoVersion={{ with index .Env "GOVERSION" }}{{ . }}{{ else }}unknown{{ end }}
|
|
goos:
|
|
- linux
|
|
- windows
|
|
- darwin
|
|
- freebsd
|
|
- netbsd
|
|
goarch:
|
|
- amd64
|
|
- arm64
|
|
- riscv64
|
|
- loong64
|
|
- arm
|
|
- s390x
|
|
- mipsle
|
|
goarm:
|
|
- "6"
|
|
- "7"
|
|
gomips:
|
|
- softfloat
|
|
main: ./web/backend
|
|
ignore:
|
|
- goos: windows
|
|
goarch: arm
|
|
- goos: netbsd
|
|
goarch: s390x
|
|
- goos: netbsd
|
|
goarch: mips64
|
|
- goos: netbsd
|
|
goarch: arm
|
|
|
|
dockers_v2:
|
|
- id: picoclaw
|
|
dockerfile: docker/Dockerfile.goreleaser
|
|
extra_files:
|
|
- docker/entrypoint.sh
|
|
ids:
|
|
- picoclaw
|
|
images:
|
|
- "ghcr.io/{{ .Env.GITHUB_REPOSITORY_OWNER }}/picoclaw"
|
|
- 'docker.io/{{ .Env.DOCKERHUB_IMAGE_NAME }}'
|
|
tags:
|
|
- '{{ if isEnvSet "NIGHTLY_BUILD" }}nightly{{ else }}{{ .Tag }}{{ end }}'
|
|
- '{{ if isEnvSet "NIGHTLY_BUILD" }}nightly{{ else }}latest{{ end }}'
|
|
platforms:
|
|
- linux/amd64
|
|
- linux/arm64
|
|
- linux/riscv64
|
|
|
|
- id: picoclaw-launcher
|
|
dockerfile: docker/Dockerfile.goreleaser.launcher
|
|
ids:
|
|
- picoclaw
|
|
- picoclaw-launcher
|
|
images:
|
|
- "ghcr.io/{{ .Env.GITHUB_REPOSITORY_OWNER }}/picoclaw"
|
|
- 'docker.io/{{ .Env.DOCKERHUB_IMAGE_NAME }}'
|
|
tags:
|
|
- '{{ if isEnvSet "NIGHTLY_BUILD" }}nightly-launcher{{ else }}{{ .Tag }}-launcher{{ end }}'
|
|
- '{{ if isEnvSet "NIGHTLY_BUILD" }}nightly-launcher{{ else }}launcher{{ end }}'
|
|
platforms:
|
|
- linux/amd64
|
|
- linux/arm64
|
|
- linux/riscv64
|
|
|
|
notarize:
|
|
macos:
|
|
- enabled: '{{ isEnvSet "MACOS_SIGN_P12" }}'
|
|
ids:
|
|
- picoclaw
|
|
- picoclaw-launcher
|
|
sign:
|
|
certificate: "{{.Env.MACOS_SIGN_P12}}"
|
|
password: "{{.Env.MACOS_SIGN_PASSWORD}}"
|
|
notarize:
|
|
issuer_id: "{{.Env.MACOS_NOTARY_ISSUER_ID}}"
|
|
key_id: "{{.Env.MACOS_NOTARY_KEY_ID}}"
|
|
key: "{{.Env.MACOS_NOTARY_KEY}}"
|
|
wait: true
|
|
timeout: 20m
|
|
|
|
archives:
|
|
- formats: [tar.gz]
|
|
# this name template makes the OS and Arch compatible with the results of `uname`.
|
|
name_template: >-
|
|
{{ .ProjectName }}_
|
|
{{- title .Os }}_
|
|
{{- if eq .Arch "amd64" }}x86_64
|
|
{{- else if eq .Arch "386" }}i386
|
|
{{- else }}{{ .Arch }}{{ end }}
|
|
{{- if .Arm }}v{{ .Arm }}{{ end }}
|
|
# use zip for windows archives
|
|
format_overrides:
|
|
- goos: windows
|
|
formats: [zip]
|
|
|
|
nfpms:
|
|
- id: picoclaw
|
|
ids:
|
|
- picoclaw
|
|
- picoclaw-launcher
|
|
package_name: picoclaw
|
|
file_name_template: >-
|
|
{{ .PackageName }}_
|
|
{{- if eq .Arch "amd64" }}x86_64
|
|
{{- else if eq .Arch "arm64" }}aarch64
|
|
{{- else if eq .Arch "arm" }}armv{{ .Arm }}
|
|
{{- else }}{{ .Arch }}{{ end }}
|
|
vendor: picoclaw
|
|
homepage: https://github.com/{{ .Env.GITHUB_REPOSITORY_OWNER }}/picoclaw
|
|
maintainer: picoclaw contributors
|
|
description: picoclaw - a tool for managing and running tasks
|
|
license: MIT
|
|
formats:
|
|
- rpm
|
|
- deb
|
|
bindir: /usr/bin
|
|
contents:
|
|
- src: web/picoclaw-launcher.desktop
|
|
dst: /usr/share/applications/picoclaw-launcher.desktop
|
|
- src: web/picoclaw-launcher.png
|
|
dst: /usr/share/icons/hicolor/512x512/apps/picoclaw-launcher.png
|
|
|
|
changelog:
|
|
sort: asc
|
|
filters:
|
|
exclude:
|
|
- "^docs:"
|
|
- "^test:"
|
|
|
|
# upx:
|
|
# - enabled: true
|
|
# compress: best
|
|
# lzma: true
|
|
|
|
release:
|
|
disable: '{{ isEnvSet "NIGHTLY_BUILD" }}'
|
|
extra_files:
|
|
- glob: ./build/picoclaw-android-universal.zip
|
|
footer: >-
|
|
|
|
---
|
|
|
|
Released by [GoReleaser](https://github.com/goreleaser/goreleaser).
|