wip
This commit is contained in:
parent
9be8a82a29
commit
912c91d60e
3 changed files with 51 additions and 1 deletions
|
|
@ -1,5 +1,6 @@
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
|
./niri.nix
|
||||||
./acpid.nix
|
./acpid.nix
|
||||||
./anyrun.nix
|
./anyrun.nix
|
||||||
./basePackages.nix
|
./basePackages.nix
|
||||||
|
|
|
||||||
|
|
@ -55,7 +55,8 @@
|
||||||
};
|
};
|
||||||
environments = lib.mkOption {
|
environments = lib.mkOption {
|
||||||
default = [
|
default = [
|
||||||
inputs.hyprland.packages.${config.conf.system}.hyprland
|
(lib.mkIf config.mods.hypr.hyprland.enable inputs.hyprland.packages.${config.conf.system}.hyprland)
|
||||||
|
(lib.mkIf config.mods.niri.enable pkgs.niri)
|
||||||
];
|
];
|
||||||
# no idea if these are written correctly
|
# no idea if these are written correctly
|
||||||
example = [
|
example = [
|
||||||
|
|
|
||||||
48
modules/programs/niri.nix
Normal file
48
modules/programs/niri.nix
Normal file
|
|
@ -0,0 +1,48 @@
|
||||||
|
{
|
||||||
|
mkDashDefault,
|
||||||
|
config,
|
||||||
|
lib,
|
||||||
|
options,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: let
|
||||||
|
browserName =
|
||||||
|
if (builtins.isString config.mods.homePackages.browser)
|
||||||
|
then config.mods.homePackages.browser
|
||||||
|
else if config.mods.homePackages.browser ? meta && config.mods.homePackages.browser.meta ? mainProgram
|
||||||
|
then config.mods.homePackages.browser.meta.mainProgram
|
||||||
|
else config.mods.homePackages.browser.pname;
|
||||||
|
in {
|
||||||
|
options.mods.niri = {
|
||||||
|
enable = lib.mkOption {
|
||||||
|
default = true;
|
||||||
|
example = false;
|
||||||
|
type = lib.types.bool;
|
||||||
|
description = ''
|
||||||
|
Enable Niri
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
config = lib.mkIf config.mods.niri.enable (
|
||||||
|
lib.optionalAttrs (options ? wayland.windowManager.hyprland) {
|
||||||
|
# TODO deduplicate and abstract away base window management config
|
||||||
|
# install Niri related packages
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
xorg.xprop
|
||||||
|
grim
|
||||||
|
slurp
|
||||||
|
satty
|
||||||
|
xdg-desktop-portal-gtk
|
||||||
|
xdg-desktop-portal-gnome
|
||||||
|
kdePackages.xdg-desktop-portal-kde
|
||||||
|
xdg-desktop-portal-shana
|
||||||
|
copyq
|
||||||
|
wl-clipboard
|
||||||
|
|
||||||
|
niri
|
||||||
|
xwayland-satellite
|
||||||
|
];
|
||||||
|
}
|
||||||
|
);
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue