2.4 KiB
2.4 KiB
Releasing
This repository uses semantic versioning and Gitea tag-based releases.
Repository Description
Use this short description in Gitea:
Rust TUI sleep timer for Linux desktop actions.
Optional longer description:
A single-binary Linux sleep timer with YAML config, command preview, progress display, and post-countdown desktop actions for niri, Hyprland, KDE, media, brightness, audio, lock, power, process kill, and custom shell commands.
Upstream
git remote add origin ssh://git@gitssh.forust.xyz:2221/forust/gosleep.git
git remote set-url --push origin ssh://git@gitssh.forust.xyz:2221/forust/gosleep.git
Public clone URL:
https://gitea.forust.xyz/forust/gosleep.git
Gitea Actions Setup
- Enable Actions for
forust/gosleep. - Register or select a Linux runner with labels used by the workflows:
self-hosted,linux,arch,homelab. - Ensure the runner has:
- Rust stable toolchain
rustfmtclippycurljqtarsha256sum- Docker, if using the YAML lint job as written
- Confirm Actions job token permissions allow
contents: write. The release workflow uses Gitea Actions' built-inGITEA_TOKEN; no extra repository secret is required.
Version Bump Checklist
For a patch bump, for example 1.1.1 to 1.1.2:
version=1.1.2
Update:
Cargo.toml:package.versionCargo.lock: package version, regenerated by CargoVERSIONCHANGELOG.md
Then verify:
cargo fmt --check
cargo test --locked
cargo clippy --locked -- -D warnings
cargo build --release --locked
Create Release
git status --short
git commit -am "chore: release v1.1.2"
git tag -a v1.1.2 -m "gosleep-timer v1.1.2"
git push origin main
git push origin v1.1.2
The .gitea/workflows/release.yaml workflow will:
- Build
target/release/gosleep-timer. - Package
gosleep-timer-<version>-linux-amd64.tar.gz. - Generate a SHA-256 checksum.
- Create a Gitea release.
- Upload the archive and checksum as release assets.
Manual Asset Build
If Actions are unavailable:
version="$(cat VERSION)"
cargo build --release --locked
mkdir -p dist
cp target/release/gosleep-timer dist/gosleep-timer
tar -C dist -czf "dist/gosleep-timer-${version}-linux-amd64.tar.gz" gosleep-timer
sha256sum "dist/gosleep-timer-${version}-linux-amd64.tar.gz" > "dist/gosleep-timer-${version}-linux-amd64.tar.gz.sha256"