diff --git a/home-manager/modules/sway/default.nix b/home-manager/modules/sway/default.nix index 21bfe22..269d377 100644 --- a/home-manager/modules/sway/default.nix +++ b/home-manager/modules/sway/default.nix @@ -63,6 +63,12 @@ in }); default = [ ]; }; + + extraKeybindings = mkOption { + description = "Extra keybindings"; + type = types.attrsOf types.str; + default = { }; + }; }; config = mkIf cfg.enable { @@ -236,7 +242,8 @@ in "${mod}+d" = "exec ${pkgs.swaynotificationcenter}/bin/swaync-client --toggle-panel --skip-wait"; "${mod}+Shift+d" = "exec ${pkgs.swaynotificationcenter}/bin/swaync-client --toggle-dnd --skip-wait"; - }; + + } // cfg.extraKeybindings; modes = { passthrough = { diff --git a/users/erwin/work.nix b/users/erwin/work.nix index 650a76f..205cc35 100644 --- a/users/erwin/work.nix +++ b/users/erwin/work.nix @@ -172,9 +172,13 @@ in }; startup = [ { command = "${ewwDaemon} --restart open bar-work"; always = true; } - { command = "${pkgs.wayvnc}/bin/wayvnc -g 0.0.0.0"; always = true; } + { command = "${pkgs.wayvnc}/bin/wayvnc 0.0.0.0"; always = true; } ]; workspaceOutputs = workspacePartition; + extraKeybindings = { + "Ctrl+Alt+1" = "exec ${pkgs.wayvnc}/bin/wayvncctl output-set DP-1"; + "Ctrl+Alt+2" = "exec ${pkgs.wayvnc}/bin/wayvncctl output-set DP-3"; + }; }; swaynotificationcenter.enable = true; tmux.enable = true;