depot/third_party/nixpkgs/pkgs/applications/window-managers/hyprwm/hyprland-plugins/default.nix
Default email bcb2f287e1 Project import generated by Copybara.
GitOrigin-RevId: d603719ec6e294f034936c0d0dc06f689d91b6c3
2024-06-20 20:27:18 +05:30

50 lines
1.4 KiB
Nix

{ lib
, callPackage
, pkg-config
, stdenv
, hyprland
}:
let
mkHyprlandPlugin = hyprland:
args@{ pluginName, ... }:
stdenv.mkDerivation (args // {
pname = "${pluginName}";
nativeBuildInputs = [ pkg-config ] ++ args.nativeBuildInputs or [ ];
buildInputs = [ hyprland ]
++ hyprland.buildInputs
++ (args.buildInputs or [ ]);
meta = args.meta // {
description = args.meta.description or "";
longDescription = (args.meta.longDescription or "") +
"\n\nPlugins can be installed via a plugin entry in the Hyprland NixOS or Home Manager options.";
};
});
plugins = {
hy3 = { fetchFromGitHub, cmake, hyprland }:
mkHyprlandPlugin hyprland rec {
pluginName = "hy3";
version = "0.41.0";
src = fetchFromGitHub {
owner = "outfoxxed";
repo = "hy3";
rev = "hl${version}";
hash = "sha256-gEEWWlQRvejSR2RRg78Lubz6siIgknqj6CslveyyIP4=";
};
nativeBuildInputs = [ cmake ];
dontStrip = true;
meta = {
homepage = "https://github.com/outfoxxed/hy3";
description = "Hyprland plugin for an i3 / sway like manual tiling layout";
license = lib.licenses.gpl3;
platforms = lib.platforms.linux;
maintainers = with lib.maintainers; [ aacebedo ];
};
};
};
in
(lib.mapAttrs (name: plugin: callPackage plugin { }) plugins) // { inherit mkHyprlandPlugin; }