also try wlopm when niri msg does not work, even if socket envvar exists

This commit is contained in:
Adam Gausmann 2025-07-29 11:00:31 -05:00
parent b7060ee406
commit a86036ebfd

View file

@ -6,9 +6,5 @@ case "$1" in
*) exit 1 ;;
esac
if [ -e "$NIRI_SOCKET" ]
then
niri msg action power-$onoff-monitors
else
wlopm --$onoff '*'
fi
[ -e "$NIRI_SOCKET" ] && niri msg action power-$onoff-monitors \
|| wlopm --$onoff '*'