Skip to content

Instantly share code, notes, and snippets.

@radgeRayden
Created February 15, 2019 21:09
Show Gist options
  • Save radgeRayden/4a3748e02d8824e14ba02a377e331498 to your computer and use it in GitHub Desktop.
Save radgeRayden/4a3748e02d8824e14ba02a377e331498 to your computer and use it in GitHub Desktop.
script to reload awesomeWM inside xephyr without "touching" the window
#!/bin/fish
#wmctrl returns a list of windows with their ids as hexadecimal.
set -l XEPHYR_WINDOW_ID (wmctrl -l | grep "Xephyr on :1.0" | grep -Eo "0x[0-9a-f]+")
set -l CURRENT_WINDOW_ID (xdotool getactivewindow)
xdotool windowfocus $XEPHYR_WINDOW_ID;
sleep 0.25s;
xdotool key ctrl+shift key super+ctrl+r key ctrl+shift;
sleep 0.25s;
xdotool windowfocus $CURRENT_WINDOW_ID;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment