plasma5Packages.polonium: init at 0.6.0

This commit is contained in:
Peter Hoeg 2023-12-06 11:20:18 +01:00
parent b169e74615
commit c979d0efb4
2 changed files with 54 additions and 2 deletions

View file

@ -0,0 +1,51 @@
{ lib
, fetchFromGitHub
, buildNpmPackage
, plasma-framework
}:
# how to update:
# 1. check out the tag for the version in question
# 2. run `prefetch-npm-deps package-lock.json`
# 3. update npmDepsHash with the output of the previous step
buildNpmPackage rec {
pname = "polonium";
version = "0.6.0";
src = fetchFromGitHub {
owner = "zeroxoneafour";
repo = pname;
rev = "v" + version;
hash = "sha256-fZgNOcOq+owmqtplwnxeOIQpWmrga/WitCNCj89O5XA=";
};
npmDepsHash = "sha256-25AtM1FweWIbFot+HUMSPYTu47/0eKNpRWSlBEL0yKk=";
dontConfigure = true;
# the installer does a bunch of stuff that fails in our sandbox, so just build here and then we
# manually do the install
buildFlags = [ "res" "src" ];
nativeBuildInputs = [ plasma-framework ];
dontNpmBuild = true;
dontWrapQtApps = true;
installPhase = ''
runHook preInstall
plasmapkg2 --install pkg --packageroot $out/share/kwin/scripts
runHook postInstall
'';
meta = with lib; {
description = "Auto-tiler that uses KWin 5.27+ tiling functionality";
license = licenses.mit;
maintainers = with maintainers; [ peterhoeg ];
inherit (plasma-framework.meta) platforms;
};
}

View file

@ -49,7 +49,7 @@ let
mirror = "mirror://kde";
};
qtStdenv = libsForQt5.callPackage ({ stdenv }: stdenv) {};
qtStdenv = libsForQt5.callPackage ({ stdenv }: stdenv) { };
packages = self:
let
@ -96,7 +96,7 @@ let
defaultSetupHook = if hasBin && hasDev then propagateBin else null;
setupHook = args.setupHook or defaultSetupHook;
nativeBuildInputs = (args.nativeBuildInputs or []) ++ [ libsForQt5.wrapQtAppsHook ];
nativeBuildInputs = (args.nativeBuildInputs or [ ]) ++ [ libsForQt5.wrapQtAppsHook ];
meta =
let meta = args.meta or { }; in
@ -183,6 +183,7 @@ let
kzones = callPackage ./3rdparty/kwin/scripts/kzones.nix { };
lightly = callPackage ./3rdparty/lightly { };
parachute = callPackage ./3rdparty/kwin/scripts/parachute.nix { };
polonium = callPackage ./3rdparty/addons/polonium.nix { };
};
} // lib.optionalAttrs config.allowAliases {