add wayland-appusage

This commit is contained in:
xunuwu 2025-03-22 21:18:13 +01:00
parent 2e4f290d21
commit 5bf102f18f
4 changed files with 99 additions and 1 deletions

73
flake.lock generated
View file

@ -109,6 +109,21 @@
"type": "github"
}
},
"crane": {
"locked": {
"lastModified": 1742394900,
"narHash": "sha256-vVOAp9ahvnU+fQoKd4SEXB2JG2wbENkpqcwlkIXgUC0=",
"owner": "ipetkov",
"repo": "crane",
"rev": "70947c1908108c0c551ddfd73d4f750ff2ea67cd",
"type": "github"
},
"original": {
"owner": "ipetkov",
"repo": "crane",
"type": "github"
}
},
"firefox-addons": {
"inputs": {
"flake-utils": "flake-utils_2",
@ -388,6 +403,24 @@
"type": "github"
}
},
"flake-utils_4": {
"inputs": {
"systems": "systems_3"
},
"locked": {
"lastModified": 1731533236,
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"fromYaml": {
"flake": false,
"locked": {
@ -874,7 +907,8 @@
"sobercookie": "sobercookie",
"sops-nix": "sops-nix",
"stylix": "stylix",
"vpn-confinement": "vpn-confinement"
"vpn-confinement": "vpn-confinement",
"wayland-appusage": "wayland-appusage"
}
},
"sobercookie": {
@ -984,6 +1018,21 @@
"type": "github"
}
},
"systems_3": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"tinted-foot": {
"flake": false,
"locked": {
@ -1146,6 +1195,28 @@
"repo": "VPN-Confinement",
"type": "github"
}
},
"wayland-appusage": {
"inputs": {
"crane": "crane",
"flake-utils": "flake-utils_4",
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1742675355,
"narHash": "sha256-cx/CEd6nx1PDtdMJWX/juRPR7XJiUK0UX/13x/eK7CE=",
"owner": "xunuwu",
"repo": "wayland-appusage",
"rev": "2ecc400910f519a9e404596ed89f4e790d579800",
"type": "github"
},
"original": {
"owner": "xunuwu",
"repo": "wayland-appusage",
"type": "github"
}
}
},
"root": "root",

View file

@ -66,5 +66,8 @@
sobercookie.url = "github:xunuwu/sobercookie";
sobercookie.inputs.nixpkgs.follows = "nixpkgs";
wayland-appusage.url = "github:xunuwu/wayland-appusage";
wayland-appusage.inputs.nixpkgs.follows = "nixpkgs";
};
}

View file

@ -0,0 +1,23 @@
{
inputs,
lib,
pkgs,
...
}: {
home.packages = [inputs.wayland-appusage.packages.${pkgs.system}.appusage];
systemd.user.services.appusage = {
Unit = {
Description = "Appusage daemon";
};
Install.WantedBy = ["sway-session.target"];
Service = {
Type = "simple";
Restart = "on-failure";
ExecStart = "${inputs.wayland-appusage.packages.${pkgs.system}.appusage-daemon}/bin/appusage-daemon";
RestartSec = "5s";
};
};
}

View file

@ -94,5 +94,6 @@
services.playerctl
services.polkit-agent
services.udiskie # although i dont need this for usb memory, it is quite convenient for flashing qmk
services.appusage
];
}