This commit is contained in:
Noa Aarts 2024-11-19 11:11:02 +01:00
parent 02588ec092
commit 2e4c560897
Signed by: noa
GPG key ID: 1850932741EFF672
2 changed files with 26 additions and 6 deletions

View file

@ -121,6 +121,9 @@ layout {
// See the binds section below for more spawn examples. // See the binds section below for more spawn examples.
// spawn-at-startup "alacritty" "-e" "fish" // spawn-at-startup "alacritty" "-e" "fish"
@automapaper@ @automapaper@
spawn-at-startup @spotify@
spawn-at-startup @keepass@
spawn-at-startup @thunderbird@
// Uncomment this line to ask the clients to omit their client-side decorations if possible. // Uncomment this line to ask the clients to omit their client-side decorations if possible.
// If the client will specifically ask for CSD, the request will be honored. // If the client will specifically ask for CSD, the request will be honored.
@ -148,6 +151,15 @@ animations {
// slowdown 3.0 // slowdown 3.0
} }
workspace "media" {
match app-id=r#"^spotify$"#
}
workspace "utils" {
match app-id=r#"^thunderbird$"#
match app-id=r#"^org\.keepassxc\.KeePassXC$"#
}
// Window rules let you adjust behavior for individual windows. // Window rules let you adjust behavior for individual windows.
// Find more information on the wiki: // Find more information on the wiki:
// https://github.com/YaLTeR/niri/wiki/Configuration:-Window-Rules // https://github.com/YaLTeR/niri/wiki/Configuration:-Window-Rules
@ -170,7 +182,7 @@ window-rule {
// Example: block out two password managers from screen capture. // Example: block out two password managers from screen capture.
// (This example rule is commented out with a "/-" in front.) // (This example rule is commented out with a "/-" in front.)
window-rule { window-rule {
match app-id=r#"^org\.keepassxc\.KeePassXC$"# match app-id=r#"^org\.gnupg\.pinentry-qt$"#
block-out-from "screen-capture" block-out-from "screen-capture"
@ -202,8 +214,8 @@ binds {
// Suggested binds for running programs: terminal, app launcher, screen locker. // Suggested binds for running programs: terminal, app launcher, screen locker.
Mod+Return { spawn "@kitty@"; } Mod+Return { spawn "@kitty@"; }
Mod+Space { spawn "@wofilaunch@"; } Mod+Space { spawn "@launcher@"; }
Mod+P { spawn "@wofipower@"; } Mod+P { spawn "@powermenu@"; }
Super+Alt+L { spawn "@swaylock@"; } Super+Alt+L { spawn "@swaylock@"; }
// You can also use a shell. Do this if you need pipes, multiple commands, etc. // You can also use a shell. Do this if you need pipes, multiple commands, etc.

View file

@ -106,8 +106,8 @@
src = ../../extra/niri.kdl; src = ../../extra/niri.kdl;
env = { env = {
kitty = "${pkgs.kitty}/bin/kitty"; kitty = "${pkgs.kitty}/bin/kitty";
wofilaunch = "${wpkgs.wofi-launch}/bin/wofi-launch"; launcher = "${wpkgs.wofi-launch}/bin/wofi-launch";
wofipower = "${wpkgs.wofi-power}/bin/wofi-power"; powermenu = "${wpkgs.wofi-power}/bin/wofi-power";
swaylock = "${pkgs.swaylock}/bin/swaylock"; swaylock = "${pkgs.swaylock}/bin/swaylock";
automapaper = lib.strings.concatMapStringsSep "\n" ( automapaper = lib.strings.concatMapStringsSep "\n" (
command: command:
@ -115,6 +115,11 @@
''spawn-at-startup "${(lib.strings.concatStringsSep ''" "'' (lib.strings.splitString " " command))}"'' ''spawn-at-startup "${(lib.strings.concatStringsSep ''" "'' (lib.strings.splitString " " command))}"''
) )
) hconfig.modules.automapaper.startStrings; ) hconfig.modules.automapaper.startStrings;
spotify = "spotify";
keepass = "keepassxc";
thunderbird = "thunderbird";
appbar = "${pkgs.waybar}/bin/waybar";
extra = lib.strings.concatStringsSep "\nspawn-at-startup \"" [ "${pkgs.dunst}/bin/dunst\"" ];
}; };
}; };
}; };
@ -160,7 +165,10 @@
package = inputs.hyprland.packages.${pkgs.system}.hyprland; package = inputs.hyprland.packages.${pkgs.system}.hyprland;
}; };
niri.enable = true; niri = {
enable = true;
package = inputs.niri.packages.${pkgs.system}.niri;
};
nix-ld.enable = true; nix-ld.enable = true;
nix-ld.libraries = with pkgs; [ nix-ld.libraries = with pkgs; [
wayland wayland