diff --git a/pkgs/by-name/co/cosmic-ext-applet-caffeine/package.nix b/pkgs/by-name/co/cosmic-ext-applet-caffeine/package.nix new file mode 100644 index 000000000000..c219968bdb6f --- /dev/null +++ b/pkgs/by-name/co/cosmic-ext-applet-caffeine/package.nix @@ -0,0 +1,55 @@ +{ + lib, + stdenv, + fetchFromGitHub, + rustPlatform, + libcosmicAppHook, + just, + nix-update-script, +}: +rustPlatform.buildRustPackage { + pname = "cosmic-ext-applet-caffeine"; + version = "2025-09-29"; + + src = fetchFromGitHub { + owner = "tropicbliss"; + repo = "cosmic-ext-applet-caffeine"; + rev = "a43db670e03894ff402fa19eec3d60f7c7bf663c"; + hash = "sha256-0hIc62FdjIGU028z8/WCx2q317e+PCA25CSibBVi/p0="; + }; + + cargoHash = "sha256-nl/giMIQ5xNSOgjv67OMWkfuAVtdIcqZDbXC1mYwXBM="; + + nativeBuildInputs = [ + libcosmicAppHook + just + ]; + + dontUseJustBuild = true; + dontUseJustCheck = true; + + justFlags = [ + "--set" + "prefix" + (placeholder "out") + "--set" + "bin-src" + "target/${stdenv.hostPlatform.rust.cargoShortTarget}/release/cosmic-ext-applet-caffeine" + ]; + + passthru.updateScript = nix-update-script { + extraArgs = [ + "--version" + "branch=HEAD" + ]; + }; + + meta = { + description = "Caffeine Applet for the COSMIC desktop"; + homepage = "https://github.com/tropicbliss/cosmic-ext-applet-caffeine"; + license = lib.licenses.mit; + mainProgram = "cosmic-ext-applet-caffeine"; + maintainers = [ lib.maintainers.HeitorAugustoLN ]; + platforms = lib.platforms.linux; + }; +}