.goreleaser.yaml RawHistoryFolder
1# Builds the ermite release for a pushed v* tag (.github/workflows/release.yml)
2# and generates the neferafk-bin PKGBUILD. The workflow verifies that PKGBUILD
3# with makepkg before it pushes it to the AUR, so GoReleaser never uploads it.
4version: 2
5
6project_name: neferafk
7
8# Releases are published on ermite. In CI the runner sets GITHUB_API_URL and
9# GITHUB_SERVER_URL to an address the job can reach; the public URLs are the
10# fallback for a local run.
11github_urls:
12 api: '{{ or (index .Env "GITHUB_API_URL") "https://git.bnema.dev/-/github/api" }}/'
13 upload: '{{ or (index .Env "GITHUB_API_URL") "https://git.bnema.dev/-/github/api" }}/uploads/'
14 download: '{{ or (index .Env "GITHUB_SERVER_URL") "https://git.bnema.dev" }}/'
15
16before:
17 hooks:
18 - go mod verify
19
20builds:
21 - id: neferafk
22 main: ./cmd/neferafk
23 binary: neferafk
24 env:
25 - CGO_ENABLED=0
26 goos: [linux]
27 goarch: [amd64, arm64]
28 flags:
29 - -trimpath
30 - -buildmode=pie
31 ldflags:
32 - -s -w -X main.version={{ .Version }}
33 # Same inputs give the same binary.
34 mod_timestamp: "{{ .CommitTimestamp }}"
35
36archives:
37 - id: neferafk
38 ids: [neferafk]
39 name_template: "{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}"
40 formats: [tar.gz]
41 # Everything the PKGBUILD package() installs, at the paths of the repo.
42 files:
43 - LICENSE
44 - README.md
45 - examples/config
46 - packaging/neferafk.pam
47
48checksum:
49 name_template: checksums.txt
50 algorithm: sha256
51
52snapshot:
53 version_template: "{{ incpatch .Version }}-next"
54
55git:
56 tag_sort: -version:refname
57
58changelog:
59 sort: asc
60 use: git
61 filters:
62 exclude:
63 - "^style(\\([^)]+\\))?:"
64 - "^test(\\([^)]+\\))?:"
65 groups:
66 - title: Added
67 regexp: "^feat(\\([^)]+\\))?!?:"
68 order: 0
69 - title: Fixed
70 regexp: "^fix(\\([^)]+\\))?!?:"
71 order: 1
72 - title: Performance
73 regexp: "^perf(\\([^)]+\\))?!?:"
74 order: 2
75 - title: Changed
76 regexp: "^(refactor|build)(\\([^)]+\\))?!?:"
77 order: 3
78 - title: Documentation
79 regexp: "^docs(\\([^)]+\\))?!?:"
80 order: 4
81 - title: Maintenance
82 regexp: "^(chore|ci)(\\([^)]+\\))?!?:"
83 order: 5
84 - title: Other changes
85 order: 999
86
87release:
88 github:
89 owner: bnema
90 name: neferafk
91 draft: false
92 prerelease: auto
93 mode: replace
94 header: |
95 ## neferafk {{ .Tag }}
96
97 ### Install on Arch Linux
98
99 ```sh
100 paru -S neferafk-bin # this release, pre-built (x86_64, aarch64)
101 paru -S neferafk-git # latest main, built from source
102 ```
103
104 ### Install the pre-built archive
105
106 Linux amd64 and arm64. Replace `amd64` with `arm64` on ARM.
107
108 ```sh
109 curl -fLO https://git.bnema.dev/neferafk/releases/download/{{ .Tag }}/neferafk_{{ .Version }}_linux_amd64.tar.gz
110 curl -fLO https://git.bnema.dev/neferafk/releases/download/{{ .Tag }}/checksums.txt
111 sha256sum -c --ignore-missing checksums.txt
112 ```
113
114 The archive holds the `neferafk` binary, the PAM service file `neferafk.pam` (install it as `/etc/pam.d/neferafk` for password mode), an example config, the README and the license. See the [README](https://git.bnema.dev/neferafk) for runtime dependencies.
115
116aurs:
117 - name: neferafk-bin
118 ids: [neferafk]
119 homepage: https://git.bnema.dev/neferafk
120 # Public URL: github_urls.download is the CI-only relay address.
121 url_template: 'https://git.bnema.dev/neferafk/releases/download/{{ .Tag }}/{{ .ArtifactName }}'
122 description: "Idle daemon for Wayland: fade, session lock, screens off and suspend"
123 maintainers:
124 - "bnema <b at bnema dot dev>"
125 license: GPL-3.0-only
126 # The release workflow verifies and publishes the generated PKGBUILD.
127 skip_upload: true
128 provides: [neferafk]
129 conflicts: [neferafk, neferafk-git]
130 # Loaded at runtime (purego, no cgo): not seen by makepkg's library scan.
131 depends:
132 - glibc
133 - pam
134 - libxkbcommon
135 - vulkan-icd-loader
136 - vulkan-driver
137 - systemd
138 - ttf-dejavu # lock screen monospace font (DejaVu Sans Mono)
139 optdepends:
140 - "pass: PIN source for auth.mode = pin"
141 backup:
142 - etc/pam.d/neferafk
143 package: |-
144 install -Dm755 ./neferafk "${pkgdir}/usr/bin/neferafk"
145 install -Dm644 ./packaging/neferafk.pam "${pkgdir}/etc/pam.d/neferafk"
146 install -Dm644 ./examples/config "${pkgdir}/usr/share/doc/neferafk/config.example"
147 install -Dm644 ./README.md "${pkgdir}/usr/share/doc/neferafk/README.md"
148 install -Dm644 ./LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"