mirror of
https://github.com/alyraffauf/nixcfg.git
synced 2024-11-24 12:31:54 -05:00
Aly Raffauf
0d0b760df9
Some checks are pending
git-mirror / gitlab-sync (push) Waiting to run
nix-build / adjustor-build (push) Waiting to run
nix-build / clean-install-build (push) Waiting to run
nix-build / hhd-ui-build (push) Waiting to run
nix-build / rofi-bluetooth-build (push) Waiting to run
nix-build / fallarbor-build (push) Waiting to run
nix-build / lavaridge-build (push) Waiting to run
nix-build / mauville-build (push) Waiting to run
nix-build / pacifidlog-build (push) Waiting to run
nix-build / rustboro-build (push) Waiting to run
nix-build / slateport-build (push) Waiting to run
nix-check / fmt-check (push) Waiting to run
nix-check / eval-check (push) Waiting to run
75 lines
2 KiB
Nix
75 lines
2 KiB
Nix
{
|
|
config,
|
|
lib,
|
|
pkgs,
|
|
...
|
|
}: let
|
|
cfg = config.ar.home;
|
|
in {
|
|
config = lib.mkIf cfg.desktop.hyprland.enable {
|
|
services.hyprpaper =
|
|
lib.mkIf
|
|
(config.stylix.enable && !cfg.services.randomWallpaper.enable)
|
|
{
|
|
enable = true;
|
|
|
|
settings = {
|
|
preload = ["${config.stylix.image}"];
|
|
wallpaper = [",${config.stylix.image}"];
|
|
};
|
|
};
|
|
|
|
wayland.windowManager.hyprland = {
|
|
enable = true;
|
|
|
|
plugins = [
|
|
pkgs.hyprlandPlugins.hyprspace
|
|
];
|
|
|
|
settings = import ./settings.nix {inherit config lib pkgs;};
|
|
|
|
systemd = {
|
|
enable = true;
|
|
variables = ["--all"];
|
|
};
|
|
|
|
extraConfig = let
|
|
moveMonitorBinds =
|
|
lib.attrsets.mapAttrsToList (
|
|
key: direction: "bind=CONTROL,${key},movecurrentworkspacetomonitor,${builtins.substring 0 1 direction}"
|
|
)
|
|
cfg.desktop.windowManagerBinds;
|
|
|
|
moveWindowBinds =
|
|
lib.attrsets.mapAttrsToList (
|
|
key: direction: "bind=,${key},movewindow,${builtins.substring 0 1 direction}"
|
|
)
|
|
cfg.desktop.windowManagerBinds;
|
|
|
|
moveWorkspaceBinds = builtins.map (x: "bind=,${toString x},workspace,${toString x}") [1 2 3 4 5 6 7 8 9];
|
|
in ''
|
|
submap=resize
|
|
binde=,down,resizeactive,0 10
|
|
binde=,left,resizeactive,-10 0
|
|
binde=,right,resizeactive,10 0
|
|
binde=,up,resizeactive,0 -10
|
|
binde=,j,resizeactive,0 10
|
|
binde=,h,resizeactive,-10 0
|
|
binde=,l,resizeactive,10 0
|
|
binde=,k,resizeactive,0 -10
|
|
bind=,escape,submap,reset
|
|
submap=reset
|
|
|
|
submap=move
|
|
${lib.strings.concatLines moveMonitorBinds}
|
|
${lib.strings.concatLines moveWindowBinds}
|
|
${lib.strings.concatLines moveWorkspaceBinds}
|
|
bind=,comma,exec,${lib.getExe pkgs.hyprnome} --previous --move
|
|
bind=,period,exec,${lib.getExe pkgs.hyprnome} --move
|
|
bind=,escape,submap,reset
|
|
submap=reset
|
|
'';
|
|
};
|
|
};
|
|
}
|