add miao battery percentage thing

This commit is contained in:
xunuwu 2025-11-23 15:39:07 +01:00
parent 0954b39733
commit 31db7d449c
Signed by: xun
SSH key fingerprint: SHA256:Uot/1WoAjWAeqLOHA5vYy4phhVydsH7jCPmBjaPZfgI
3 changed files with 30 additions and 0 deletions

View file

@ -0,0 +1,23 @@
{
rustPlatform,
pkg-config,
udev,
fetchFromGitHub,
}:
rustPlatform.buildRustPackage rec {
pname = "miao-battery-percentage";
version = "0.1.0";
src = fetchFromGitHub {
owner = "xunuwu";
repo = "miao-battery-percentage";
rev = "e14e72dce9d946503676121759ce6130e42bb637";
hash = "sha256-NXJv8dChKPv695XMvmm+Xh0VJ1jdRhbdGMCM0LVIiD8=";
};
cargoLock.lockFile = "${src}/Cargo.lock";
nativeBuildInputs = [pkg-config];
buildInputs = [udev];
meta.mainProgram = "miao-battery-percentage";
}