gamemode 1080p 330hz toggle
This commit is contained in:
17
home_dotfiles/.config/sway/display-profile-status.sh
Normal file
17
home_dotfiles/.config/sway/display-profile-status.sh
Normal file
@@ -0,0 +1,17 @@
|
||||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
PROFILE_FILE="/home/raga/.config/sway/display-profile.conf"
|
||||
|
||||
mode_str=""
|
||||
if [[ -f "$PROFILE_FILE" ]]; then
|
||||
mode_str="$(awk '$1=="set" && $2=="$dp1_mode" {print $3; found=1} END {if(!found) print ""}' "$PROFILE_FILE" 2>/dev/null)"
|
||||
fi
|
||||
|
||||
# Display-related FontAwesome icon + a short label.
|
||||
case "$mode_str" in
|
||||
3840x2160@*|4096x2160@*) echo " 4K";;
|
||||
1920x1080@*) echo " 1080p";;
|
||||
"") echo "";;
|
||||
*) echo " ${mode_str}";;
|
||||
esac
|
||||
Reference in New Issue
Block a user