add rofi-ssh script

This commit is contained in:
Thomas Avé 2024-04-21 18:28:35 +02:00
parent 0447f68106
commit d9118de373
2 changed files with 10 additions and 0 deletions

View File

@ -140,6 +140,7 @@ bind = $mainMod, SPACE, togglesplit, # dwindle
bind = CONTROL_L ALT_L, L, exec, swaylock
bind = $mainMod, C, exec, cliphist list | awk '{print $0, "\0icon\x1fcom.github.davidmhewitt.clipped"}' | rofi -dmenu -display-columns 2 | cliphist decode | wl-copy
bind = $mainMod, Y, exec, /home/user/.config/rofi/rofi-ykman.sh
bind = $mainMod, N, exec, /home/user/.config/rofi/rofi-ssh.sh
bind = $mainMod, Escape, exec, rofi -show power-menu -modi power-menu:$scripts/rofi-power-menu

9
.config/rofi/rofi-ssh.sh Executable file
View File

@ -0,0 +1,9 @@
#!/usr/bin/env bash
servers=(Mallorea Kell Riva Vault Aloria Arendia)
selected=$(for server in "${servers[@]}"; do printf "%s\0icon\x1fyubioath\n" "$server"; done | rofi -dmenu -i)
if [ -z "$selected" ]; then
exit 1
fi
alacritty -e zsh -c "source ~/.zshrc && run_waypipe $selected"