mirror of
https://github.com/CoolnsX/hyprdots.git
synced 2025-12-20 15:25:24 +05:30
feat: updated creds
This commit is contained in:
@@ -38,16 +38,17 @@ case $1 in
|
||||
;;
|
||||
focus)
|
||||
#shows the workspace number as notification whenever u switch workspaces and also handles the dual monitor setup on the fly(perfect for laptop users)
|
||||
socat - "UNIX-CONNECT:/tmp/hypr/$HYPRLAND_INSTANCE_SIGNATURE/.socket2.sock" | while read -r line; do
|
||||
printf "%s" "$line" | grep -q "monitoradded" && handle_it "$line"
|
||||
socat - "UNIX-CONNECT:$XDG_RUNTIME_DIR/hypr/$HYPRLAND_INSTANCE_SIGNATURE/.socket2.sock" | while read -r line; do
|
||||
printf "%s" "$line" | grep -qE "monitoraddedv2.*HEADLESS" && continue
|
||||
printf "%s" "$line" | grep -q "monitoraddedv2" && handle_it "$line"
|
||||
printf "%s" "$line" | grep -q "monitorremoved" && sed -i "s/monitor=,1920x1080,0x0,1,mirror,eDP-1/monitor=,highrr,auto,1/g" "$HOME/.config/hypr/hyprland.conf" && eww kill && eww open_many time_0 music_0
|
||||
#recent workspace switcher
|
||||
current=$(printf "%s" "$line" | sed -nE 's_^(workspace)>>([^ ]*)_\1 \2_p')
|
||||
current=$(printf "%s" "$line" | sed -nE 's_^(workspace)v2>>([^,]*),.*_\1 \2_p')
|
||||
if [ -n "$current" ]; then
|
||||
cat /tmp/workcurr >/tmp/workprev
|
||||
printf "%s" "$current" >/tmp/workcurr
|
||||
fi
|
||||
notify-send -e -i "lol" "$(printf "%s" "$line" | sed -nE 's_^(workspace)>>([^ ]*)_\1 \2_p')" -h "string:x-canonical-private-synchronous:monitor" -t 700 2>/dev/null
|
||||
notify-send -e -i "lol" "$current" -h "string:x-canonical-private-synchronous:monitor" -t 700 2>/dev/null
|
||||
done
|
||||
;;
|
||||
toggle)
|
||||
|
||||
Reference in New Issue
Block a user