-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.goreleaser.yml
More file actions
197 lines (169 loc) · 4.72 KB
/
.goreleaser.yml
File metadata and controls
197 lines (169 loc) · 4.72 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
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
# GoReleaser configuration for gohome
# Simplified config focusing on curl|sh and go install methods
# See https://goreleaser.com for more details
version: 2
before:
hooks:
- go mod tidy
- go generate ./...
builds:
- id: gohome
binary: gohome
main: ./cmd/gohome
env:
- CGO_ENABLED=0
goos:
- linux
- darwin
- windows
goarch:
- amd64
- arm64
flags:
- -trimpath
ldflags:
- -s -w
- -X github.com/anIcedAntFA/gohome/internal/version.Version={{.Version}}
- -X github.com/anIcedAntFA/gohome/internal/version.Commit={{.Commit}}
- -X github.com/anIcedAntFA/gohome/internal/version.Date={{.Date}}
ignore:
- goos: windows
goarch: arm64
archives:
- id: gohome
name_template: >-
{{ .ProjectName }}_
{{- .Version }}_
{{- .Os }}_
{{- if eq .Arch "amd64" }}x86_64
{{- else if eq .Arch "386" }}i386
{{- else }}{{ .Arch }}{{ end }}
{{- if .Arm }}v{{ .Arm }}{{ end }}
files:
- README.md
- LICENSE
# Source archive for AUR
source:
enabled: true
name_template: "{{ .ProjectName }}-{{ .Version }}"
format: "tar.gz"
checksum:
name_template: "checksums.txt"
algorithm: sha256
snapshot:
version_template: "{{ incpatch .Version }}-next"
changelog:
sort: asc
use: github
filters:
exclude:
- "^docs:"
- "^test:"
- "^ci:"
- "^chore:"
- "^style:"
- "^refactor:"
- Merge pull request
- Merge branch
groups:
- title: "New Features"
regexp: "^.*feat[(\\w)]*:+.*$"
order: 0
- title: "Bug Fixes"
regexp: "^.*fix[(\\w)]*:+.*$"
order: 1
- title: "Performance Improvements"
regexp: "^.*perf[(\\w)]*:+.*$"
order: 2
- title: "Other Changes"
order: 999
release:
github:
owner: anIcedAntFA
name: gohome
draft: false
prerelease: auto
mode: replace
header: |
## Installation
### Quick Install (Linux/macOS)
```bash
curl -sS https://get.ngockhoi96.dev/gohome | sh
```
### Quick Install (Windows PowerShell)
```powershell
irm https://raw.githubusercontent.com/anIcedAntFA/gohome/main/scripts/install.ps1 | iex
```
### Arch Linux (AUR)
```bash
yay -S gohome
# or
paru -S gohome
```
### NPM
```bash
npm install -g @ngockhoi96/gohome
```
### Go Install
```bash
go install github.com/anIcedAntFA/gohome/cmd/gohome@latest
```
### Download Binary
Download the appropriate binary for your platform below.
footer: |
## Full Changelog
**Full Changelog**: https://github.com/anIcedAntFA/gohome/compare/{{ .PreviousTag }}...{{ .Tag }}
---
Questions? Feedback? Open an issue: https://github.com/anIcedAntFA/gohome/issues
project_name: gohome
dist: dist
# AUR (Arch User Repository) - Build from source
aur_sources:
- name: gohome
homepage: "https://github.com/anIcedAntFA/gohome"
description: "A fast, configurable Git standup & activity reporting CLI written in Go"
maintainers:
- "ngockhoi96 <ngockhoi96.dev@gmail.com>"
license: "MIT"
# SSH private key for pushing to AUR
# Store the key content in GitHub Secrets as AUR_SSH_PRIVATE_KEY
private_key: "{{ .Env.AUR_SSH_PRIVATE_KEY }}"
# AUR Git repository URL
git_url: "ssh://aur@aur.archlinux.org/gohome.git"
# Skip upload for prereleases
skip_upload: auto
# Package metadata
provides:
- gohome
conflicts:
- gohome-bin
# Build dependencies (Go and Git are included by default)
makedepends:
- go
- git
# Commit message template
commit_msg_template: "Update to {{ .Tag }}"
# Custom build instructions for Arch
# This follows Arch packaging guidelines
# Note: GoReleaser source archive extracts directly to $srcdir (no wrapper directory)
build: |-
cd "$srcdir"
export CGO_ENABLED=0
export CGO_CPPFLAGS="${CPPFLAGS}"
export CGO_CFLAGS="${CFLAGS}"
export CGO_CXXFLAGS="${CXXFLAGS}"
export CGO_LDFLAGS="${LDFLAGS}"
export GOFLAGS="-buildmode=pie -trimpath -mod=readonly -modcacherw"
go build \
-ldflags="-s -w \
-X github.com/anIcedAntFA/gohome/internal/version.Version=${pkgver} \
-X github.com/anIcedAntFA/gohome/internal/version.Commit={{ .Commit }} \
-X github.com/anIcedAntFA/gohome/internal/version.Date={{ .Date }}" \
-o gohome \
./cmd/gohome
# Custom package installation instructions
package: |-
cd "$srcdir"
install -Dm755 gohome "${pkgdir}/usr/bin/gohome"
install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
install -Dm644 README.md "${pkgdir}/usr/share/doc/${pkgname}/README.md"