CI / check (push) Successful in 1m34s
A swayidle-shaped daemon: `present <cmd>` runs when a Bluetooth LE device comes within an RSSI threshold, `absent <secs> <cmd>` once nobody has for that long. Near means 3 of the last 5 advertisements at or above -58 dBm by default; --calibrate prints the raw stream so the threshold is picked at the installed screen, not guessed. Nothing is stored: a few seconds of samples in memory, counted. Packaged for the [uhhm] registry from the checkout itself, built natively per arch on tag by Gitea Actions, with the version checked across Cargo.toml, PKGBUILD and the tag. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
32 lines
1.1 KiB
Bash
32 lines
1.1 KiB
Bash
# Maintainer: bl <bendik@lynghaug.me>
|
|
# Built from the checkout it sits in: .gitea/workflows/release.yml runs makepkg
|
|
# at the repo root on a v* tag, natively per arch, and uploads to the [uhhm]
|
|
# registry. pkgver must match Cargo.toml and the tag; CI checks all three.
|
|
#
|
|
# source=() and $startdir on purpose: makepkg's own $srcdir is ./src, which is
|
|
# where the Rust sources live, so copying into it would nest src/src. Cargo
|
|
# builds in place into ./target (gitignored) instead.
|
|
|
|
pkgname=presence
|
|
pkgver=0.1.0
|
|
pkgrel=1
|
|
pkgdesc="BLE proximity events for a kiosk screen, swayidle style"
|
|
arch=('x86_64' 'aarch64')
|
|
url="https://project.uhhm.no/uhhm/presence"
|
|
license=('MIT')
|
|
depends=('bluez' 'dbus' 'gcc-libs' 'glibc')
|
|
makedepends=('cargo')
|
|
source=()
|
|
|
|
build() {
|
|
cd "$startdir"
|
|
CARGO_TARGET_DIR="$startdir/target" cargo build --release --locked
|
|
}
|
|
|
|
package() {
|
|
cd "$startdir"
|
|
install -Dm755 target/release/presence "$pkgdir/usr/bin/presence"
|
|
install -Dm644 README.md "$pkgdir/usr/share/doc/presence/README.md"
|
|
install -Dm644 LICENSE "$pkgdir/usr/share/licenses/presence/LICENSE"
|
|
}
|