Move sway menu command to a file in order to let it exec properly
diff --git a/1 b/1
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/1
diff --git a/src/apps/personal/sway.nix b/src/apps/personal/sway.nix
index 5be7a4f..5a4ed8c 100644
--- a/src/apps/personal/sway.nix
+++ b/src/apps/personal/sway.nix
@@ -84,7 +84,7 @@
                 "XF86MonBrightnessDown" = "exec lightctl down -s 200";
                 "${modifier}+Shift+s" = "exec grim -g \"$(slurp)\" - | tee ~/Screenshots/\"$(date --rfc-3339=seconds)\".png | wl-copy";
                 "${modifier}+g" = "sticky toggle";
-                "${modifier}+minus" = "exec swaymsg -t get_tree | jq -r '.nodes[].nodes[] | select(.name == \"__i3_scratch\").floating_nodes[] | ((.id | tostring) + \"\t\" + (.app_id // .window_properties.class) + \"\t\" + .name)' | rofi -dmenu | { read -r id name && swaymsg \"[con_id=$id]\" focus }";
+                "${modifier}+minus" = "exec ${./sway/show-menu.sh}";
             };
             keycodebindings = {};
             left = "h";
diff --git a/src/apps/personal/sway/show-menu.sh b/src/apps/personal/sway/show-menu.sh
new file mode 100755
index 0000000..edbe00b
--- /dev/null
+++ b/src/apps/personal/sway/show-menu.sh
@@ -0,0 +1,3 @@
+export id="$(swaymsg -t get_tree | jq -r '.nodes[].nodes[] | select(.name == "__i3_scratch").floating_nodes[] | ((.id | tostring) + "\t" + (.app_id // .window_properties.class) + "\t" + .name)' | rofi -dmenu | awk '{print $1;}')"
+echo Showing $id
+swaymsg "[con_id=$id]" focus