Feat: New Scripts, new functions

This commit is contained in:
coolnsx
2025-10-22 14:17:33 +05:30
parent 135b8ce642
commit 46ba34c8e5
26 changed files with 469 additions and 353 deletions

21
hypr/pinmpv Executable file
View File

@@ -0,0 +1,21 @@
#!/bin/sh
# make window floating
hyprctl dispatch togglefloating
socket_file="/tmp/jellyfin-mpvsocket"
# use fallback if specified file doesn't exist
[ -e "$socket_file" ] || socket_file="/tmp/mpvsocket"
# dimension to resize the mpv window
dimension=$(printf '{ "command": ["get_property", "width"] }\n{ "command": ["get_property", "height"] }\n' | socat - "$socket_file" | sed -nE 's|.*"data":([^,]*),.*|\1|p' | tr '\n' ' ')
# resize window to match video resolution
hyprctl dispatch resizeactive exact $dimension
# move window to bottom right
hyprctl dispatch movewindow r
hyprctl dispatch movewindow d
#pin
#hyprctl dispatch pin