hyprshutdown: track releases rather than unstable commits

This is possible now that v0.1.0 has been released. Note that this
commit does not include any actual updates.

This also permits us to use versionCheckHook, which removes the need for
the runCommand test.
This commit is contained in:
MithicSpirit
2026-01-29 19:27:16 -05:00
parent 1470e0b051
commit 055b5a79e4
+8 -16
View File
@@ -13,17 +13,17 @@
hyprgraphics,
cairo,
nix-update-script,
testers,
versionCheckHook,
}:
gcc15Stdenv.mkDerivation (finalAttrs: {
pname = "hyprshutdown";
version = "0-unstable-2026-01-27";
version = "0.1.0";
src = fetchFromGitHub {
owner = "hyprwm";
repo = "hyprshutdown";
rev = "9f18be9c4e1a484c65b22dd53280815dc79a5a56";
tag = "v${finalAttrs.version}";
hash = "sha256-dp5lyZzKsjdqJLfwr0S4ILets8eu1kLfBB2y/LxspsU=";
};
@@ -43,20 +43,12 @@ gcc15Stdenv.mkDerivation (finalAttrs: {
(glaze.override { enableSSL = false; })
];
doInstallCheck = true;
nativeInstallCheckInputs = [ versionCheckHook ];
versionCheckProgramArg = "--help";
passthru = {
updateScript = nix-update-script {
# TODO: remove when stable release available
extraArgs = [ "--version=branch" ];
};
tests = {
help = testers.runCommand {
name = "${finalAttrs.pname}-help-test";
nativeBuildInputs = [ finalAttrs.finalPackage ];
script = ''
'${finalAttrs.meta.mainProgram}' --help && touch "$out"
'';
};
};
updateScript = nix-update-script { };
};
meta = {