-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.goreleaser.yml
More file actions
120 lines (111 loc) · 3.17 KB
/
.goreleaser.yml
File metadata and controls
120 lines (111 loc) · 3.17 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
version: 2
project_name: onvif-simulator
before:
# Populate internal/ffmpeg/binaries/<goos>_<goarch>/ffmpeg{,.exe} with
# real LGPL static builds before any `go build` runs. The script is
# idempotent — earlier builds in the same release see the binaries
# already in place and skip re-fetching. Pin per-platform SHA-256s in
# scripts/ffmpeg.sha256 before release; the script refuses unpinned
# downloads.
hooks:
- ./scripts/fetch-ffmpeg.sh linux amd64
- ./scripts/fetch-ffmpeg.sh linux arm64
- ./scripts/fetch-ffmpeg.sh linux arm
- ./scripts/fetch-ffmpeg.sh darwin amd64
- ./scripts/fetch-ffmpeg.sh darwin arm64
- ./scripts/fetch-ffmpeg.sh windows amd64
- ./scripts/fetch-ffmpeg.sh windows arm64
builds:
- id: cli
main: ./cmd/cli
binary: onvif-simulator
env:
- CGO_ENABLED=0
goos:
- linux
- darwin
- windows
goarch:
- amd64
- arm64
ldflags:
- -s -w
- -X github.com/GyeongHoKim/onvif-simulator/internal/version.Version={{.Version}}
- -X github.com/GyeongHoKim/onvif-simulator/internal/version.Commit={{.Commit}}
- -X github.com/GyeongHoKim/onvif-simulator/internal/version.Date={{.Date}}
# Raspberry Pi build channel. Embeds mtxrpicam (32+64) so the artifact runs
# standalone on Raspberry Pi OS with libcamera. The pre hook fetches the
# binary blob from the pinned mediamtx release; the rpicam build tag selects
# the rpicamera runtime in internal/rpicamera.
- id: cli-rpi
main: ./cmd/cli
binary: onvif-simulator-rpi
env:
- CGO_ENABLED=0
flags:
- -tags=rpicam
goos:
- linux
goarch:
- arm
- arm64
goarm:
- "7"
hooks:
pre:
- cmd: ./scripts/fetch-mtxrpicam.sh {{ if eq .Arch "arm" }}32{{ else }}64{{ end }} v2.5.6 internal/rpicamera/mtxrpicam_{{ if eq .Arch "arm" }}32{{ else }}64{{ end }}
ldflags:
- -s -w
- -X github.com/GyeongHoKim/onvif-simulator/internal/version.Version={{.Version}}
- -X github.com/GyeongHoKim/onvif-simulator/internal/version.Commit={{.Commit}}
- -X github.com/GyeongHoKim/onvif-simulator/internal/version.Date={{.Date}}
archives:
- id: cli
ids:
- cli
formats:
- tar.gz
format_overrides:
- goos: windows
formats:
- zip
name_template: "{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}"
- id: cli-rpi
ids:
- cli-rpi
formats:
- tar.gz
name_template: "{{ .ProjectName }}-rpi_{{ .Version }}_{{ .Os }}_{{ .Arch }}"
checksum:
name_template: "checksums.txt"
algorithm: sha256
changelog:
use: github
sort: asc
groups:
- title: Features
regexp: "^feat"
order: 0
- title: Bug Fixes
regexp: "^fix"
order: 1
- title: Others
order: 999
filters:
exclude:
- "^docs"
- "^chore"
- "^ci"
- "Merge pull request"
release:
github:
owner: GyeongHoKim
name: onvif-simulator
draft: false
prerelease: auto
name_template: "v{{.Version}}"
extra_files:
- glob: ./scripts/install.sh
- glob: ./scripts/install.ps1
- glob: ./onvif-simulator.example.json
- glob: ./onvif-simulator.example.rpi.json