Sway-config/.config/sway/toggle_gammastep.sh

14 lines
233 B
Bash
Raw Permalink Normal View History

2023-03-23 16:15:34 +01:00
#!/usr/bin/bash
2023-03-23 15:46:11 +01:00
# This script will toggle gammastep
2023-03-23 16:15:34 +01:00
# Dependencies: gammastep
2023-03-23 15:46:11 +01:00
2023-03-23 18:20:35 +01:00
PID="$(ps -e | grep gammastep | awk '{print $1}')"
2023-03-23 15:46:11 +01:00
if [[ $PID > 0 ]]; then
kill $PID
else
2023-03-23 16:15:34 +01:00
gammastep-indicator -c .config/sway/gammastep.ini
2023-03-23 15:46:11 +01:00
fi
exit 0