I got a little crazy here. a lot of laptop poop

This commit is contained in:
Chris Cochrun 2021-09-22 09:58:13 -05:00
parent 263d10c080
commit fab3b36dec
47 changed files with 3726 additions and 189 deletions

30
scripts/fflof Executable file
View file

@ -0,0 +1,30 @@
#!/bin/sh
# Check to see if firefox is running
if [ $(pgrep -c firefox) -gt 0 ]; then
if [ $XDG_SESSION_TYPE = "x11" ]; then
#X11
ffrg=$(wmctrl -lx | rg firefox | awk '{print $1}')
# echo $emacsrg
if [ -z $ffrg ]; then
firefox
exit
else
wmctrl -ia $ffrg
exit
fi
else
# WAYLAND
ffrg=$(wlrctl window list | rg firefox)
ffwin=$(echo $ffrg | sed 's/.*\: //')
# echo $ffwin
wlrctl toplevel focus title:"$ffwin"
exit
fi
else
firefox
fi