diff --git a/flake.lock b/flake.lock index 1ddf163..fa59a81 100644 --- a/flake.lock +++ b/flake.lock @@ -1,5 +1,25 @@ { "nodes": { + "clippyboard": { + "inputs": { + "nixpkgs": [ + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1758224382, + "narHash": "sha256-EQwtymWm+QLeRH35kPZdvGBwyuNsK7zvshg91O/FS7U=", + "owner": "Noratrieb", + "repo": "clippyboard", + "rev": "660afa0bc8f932c9cb13da5b4e1f3e1524c27085", + "type": "github" + }, + "original": { + "owner": "Noratrieb", + "repo": "clippyboard", + "type": "github" + } + }, "flake-parts": { "inputs": { "nixpkgs-lib": [ @@ -219,6 +239,7 @@ }, "root": { "inputs": { + "clippyboard": "clippyboard", "home-manager": "home-manager", "minegrub-theme": "minegrub-theme", "niri": "niri", diff --git a/flake.nix b/flake.nix index 24251bf..cc60479 100644 --- a/flake.nix +++ b/flake.nix @@ -19,6 +19,9 @@ niri.url = "github:sodiboo/niri-flake"; + clippyboard.url = "github:Noratrieb/clippyboard"; + clippyboard.inputs.nixpkgs.follows = "nixpkgs"; + # for firefox-nightly # firefox.url = "github:nix-community/flake-firefox-nightly"; # firefox.inputs.nixpkgs.follows = "nixpkgs"; diff --git a/home-manager/config.kdl b/home-manager/config.kdl index 04d2bde..93d99c5 100644 --- a/home-manager/config.kdl +++ b/home-manager/config.kdl @@ -334,6 +334,11 @@ window-rule { open-on-output "Lenovo Group Limited LEN G25-10 U4B30R14" } +window-rule { + match app-id="clippyboard" + open-floating true +} + binds { // Keys consist of modifiers separated by + signs, followed by an XKB key name // in the end. To find an XKB name for a particular key, you may use a program @@ -550,8 +555,8 @@ binds { Mod+Shift+KP_Add { set-window-height "+10%"; } // Move the focused window between the floating and the tiling layout. - Mod+V { toggle-window-floating; } - Mod+Shift+V { switch-focus-between-floating-and-tiling; } + Mod+P { toggle-window-floating; } + Mod+Shift+P { switch-focus-between-floating-and-tiling; } // move around floating windows, sadly not available via binds directly. Mod+Alt+Up { spawn "niri" "msg" "action" "move-floating-window" "-y" "-50"; } @@ -593,7 +598,6 @@ binds { Mod+Shift+E { quit; } Ctrl+Alt+Delete { quit; } - // Powers off the monitors. To turn them back on, do any input like - // moving the mouse or pressing any other key. - Mod+Shift+P { power-off-monitors; } + // Paste from clippyboard + Mod+V { spawn "clippyboard-select"; } } diff --git a/nixos/configuration.nix b/nixos/configuration.nix index fce042a..dcdc35c 100644 --- a/nixos/configuration.nix +++ b/nixos/configuration.nix @@ -13,6 +13,7 @@ in # inputs.hardware.nixosModules.common-ssd inputs.niri.nixosModules.niri + inputs.clippyboard.nixosModules.default ]; nixpkgs = { @@ -134,6 +135,8 @@ in }; programs.waybar.enable = true; + services.clippyboard.enable = true; + services.flatpak.enable = true; console.keyMap = "sg";