forked from satisfactorymodding/SatisfactoryModManager
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.goreleaser.yml
116 lines (89 loc) · 3.01 KB
/
.goreleaser.yml
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
project_name: SatisfactoryModManager
before:
hooks:
- go generate -x -tags tools ./...
- go mod tidy
- ./.github/convertWailsJsonPaths.sh
# Apparently only wails build generates the embedded directory
- mkdir -p frontend/build
- touch frontend/build/.gitkeep
- wails generate module
- pnpm -C frontend install
- pnpm -C frontend build
### Build
builds:
- id: standalone
goos:
- linux
goarch:
- amd64
# Wails v2 apps cannot be built using regular go build, and must use wails build
# However, wails takes only the filename as the -o argument, so we use a wrapper that handles that
gobinary: "./.github/wailsWrapper.sh"
ldflags:
# The default args
- -s -w -X main.version={{.Version}} -X main.commit={{.Commit}} -X main.date={{.Date}}
# Auto-update mode
- -X main.updateMode=standalone
flags:
- -s
- -skipbindings
- id: package-manager
goos:
- linux
goarch:
- amd64
# Wails v2 apps cannot be built using regular go build, and must use wails build
# However, wails takes only the filename as the -o argument, so we use a wrapper that handles that
gobinary: "./.github/wailsWrapper.sh"
ldflags:
# The default args
- -s -w -X main.version={{.Version}} -X main.commit={{.Commit}} -X main.date={{.Date}}
# Auto-update mode
- -X main.updateMode=package-manager
flags:
- -s
- -skipbindings
- id: nsis
binary: SatisfactoryModManager-Setup # This name must match the nsis script OutFile, so the installer overwrites the wails built exe
goos:
- windows
goarch:
- amd64
# Wails v2 apps cannot be built using regular go build, and must use wails build
# However, wails takes only the filename as the -o argument, so we use a wrapper that handles that
gobinary: "./.github/wailsWrapper.sh"
ldflags:
# The default args
- -s -w -X main.version={{.Version}} -X main.commit={{.Commit}} -X main.date={{.Date}}
# Auto-update mode
- -X autoupdate.updateMode=nsis
flags:
- -s
- -skipbindings
- -nsis
### Package
archives:
- id: windows-nsis
builds:
- nsis
format: binary
name_template: SatisfactoryModManager-Setup
- id: standalone
builds:
- standalone
format: binary
name_template: "{{ .ProjectName }}_{{ .Os }}_{{ .Arch }}{{ with .Arm }}v{{ . }}{{ end }}{{ with .Mips }}_{{ . }}{{ end }}"
checksum:
name_template: 'checksums.txt'
### Release
snapshot:
name_template: '{{ .Version }}+{{ if ne .Branch "master" }}{{ .Branch }}.{{ end }}{{ .ShortCommit }}'
release:
draft: true
name_template: "{{.ProjectName}} v{{.Version}}"
# Include all artifacts: windows-nsis, standalone
header: |
## Installation
Download and run `SatisfactoryModManager-Setup.exe` (Windows) or `SatisfactoryModManager_linux_win64` (Linux)
If you already have Satisfactory Mod Manager installed, you don't need to download it again, it will auto-update.