#rofi -show run #monitor="$(swaymsg -t get_outputs | jq '[.[].focused] | index(true)')" #monitor=""$(swaymsg -t get_workspaces | jq -e "map(select(.focused == true).num)[0]-(.|length)" | tr -d "-") # get the focused monitor - kanshi could mess up the order so we get the monitorname instead monitor="$(swaymsg -t get_outputs | jq -c '.[] | select(.focused) | select(.id)' | jq -c '.name')" # show rofi on the focused monitor rofi -show run -modi "run,drun,ssh,window" -sidebar-mode -show-icons -monitor "$monitor"