summaryrefslogtreecommitdiff
path: root/hm/env/niri/binds.nix
diff options
context:
space:
mode:
authoradikro <adikro@disroot.org>2026-03-15 22:13:15 +0100
committeradikro <adikro@disroot.org>2026-03-15 22:13:15 +0100
commit18f08bf53591f3e68043730a627889957009deb6 (patch)
tree228a31ab5489e98253e963424cd064d57dcd7a6e /hm/env/niri/binds.nix
parent8eb0e90219a4de87d8d476e15329e14720f091c6 (diff)
browser stuff
Diffstat (limited to 'hm/env/niri/binds.nix')
-rw-r--r--hm/env/niri/binds.nix10
1 files changed, 10 insertions, 0 deletions
diff --git a/hm/env/niri/binds.nix b/hm/env/niri/binds.nix
index 27eb583..c5c1f56 100644
--- a/hm/env/niri/binds.nix
+++ b/hm/env/niri/binds.nix
@@ -11,6 +11,15 @@ let
ssPath = "${toString config.hm.conf.xdg-dirs.storagePath}/pics/ss/$(date +%Y-%m-%d_%H-%M-%S)";
obsEnabled = config.hm.soft.obs.enable or false;
obsPass = if obsEnabled then osConfig.sops.secrets."obs/websocket_password".path else "";
+ otter-menu = pkgs.writeShellScriptBin "otter-menu" ''
+ ${pkgs.foot}/bin/footclient -a otter-launcher otter-launcher &
+ ${pkgs.niri}/bin/niri msg event-stream | while read -r line; do
+ if echo "$line" | ${pkgs.ripgrep-all}/bin/rga -aq "Window focus changed"; then
+ ${pkgs.procps}/bin/pkill -f "otter-launcher"
+ exit 0
+ fi
+ done
+ '';
in
{
# --- System & Media ---
@@ -46,6 +55,7 @@ in
"Super+B".action = spawn "librewolf";
"Super+S".action = spawn "spotify";
"Super+E".action = spawn "thunar";
+ "Super+Space".action = spawn "${otter-menu}/bin/otter-menu";
# --- Navigation: Columns & Workspaces ---
"Mod+H".action = focus-column-or-monitor-left;