Feature/goreleaser :: Added goreleaser.yaml

This commit is contained in:
Rene 2022-09-27 17:50:45 -06:00
parent 0c49949a5d
commit 99d1c47f18
3 changed files with 49 additions and 0 deletions

View file

@ -39,4 +39,7 @@ clean:
rm src/$(DNAME) || true
docker rmi -f $(DUSER)/$(DNAME)
release:
cd src; curl -sfL https://goreleaser.com/static/run | bash -s -- release
dev: docker-build docker-run

View file

@ -69,6 +69,22 @@ SHOUTRRR_URL="gotify://192.168.2.1:8083/AwQqpAae.rrl5Ob/?title=Unknown host dete
THEME="darkly"
```
## Releases
WatchYourLAN uses goreleaser to generate multi-platform releases.
Generate a token here: https://github.com/settings/tokens/new
Add as an environment variable:
```shell
export GITHUB_TOKEN=<TOKEN GOES HERE>
```
Run goreleaser:
```
curl -sfL https://goreleaser.com/static/run | bash -s -- release
```
## Thanks
- All go packages listed in [dependencies](https://github.com/aceberg/WatchYourLAN/network/dependencies)
- Favicon and logo: [Access point icons created by Freepik - Flaticon](https://www.flaticon.com/free-icons/access-point)

30
src/.goreleaser.yaml Normal file
View file

@ -0,0 +1,30 @@
# This is an example .goreleaser.yml file with some sensible defaults.
# Make sure to check the documentation at https://goreleaser.com
before:
hooks:
- go mod tidy
- go generate ./...
builds:
- env:
- CGO_ENABLED=0
goos:
- linux
- windows
- darwin
archives:
- replacements:
darwin: Darwin
linux: Linux
windows: Windows
386: i386
amd64: x86_64
checksum:
name_template: 'checksums.txt'
snapshot:
name_template: "{{ incpatch .Version }}-next"
changelog:
sort: asc
filters:
exclude:
- '^docs:'
- '^test:'