moved hypr scripts

This commit is contained in:
djaidjai committed 2026-10-02 02:06:46 +02:00
1 parent 37fb63549e
commit f338147907
22 files changed
+610 -5

No files matched your search

+25
View File
@@ -0,0 +1,25 @@
#!/usr/bin/env bash
# This script allows the user to make a screenshot (through slurp)
# and will then open said screenshot from the clipboard into feh
# it will also make the feh window floating, and move it to the original position of the selection
slop=$(slurp -f "%x,%y %wx%h" || exit 1)
# If the capture was cancelled, out will be empty
if [[ -n "$slop" ]]; then
# get x,y of selection
coords=$(echo "$slop" | awk -F' ' '{print $1}')
x=$(echo "$coords" | awk -F',' '{print $1}')
y=$(echo "$coords" | awk -F',' '{print $2}')
grim -g "$slop" - | wl-copy
grim -g "$slop" - | feh - -T notitle --class 'floatme' &
pid="$!"
while [[ -z $(wmctrl -lp | awk -vpid=$pid '$3==pid {print $1; exit}') ]]; do
sleep 0.05
done
hyprctl dispatch "hl.dsp.window.move({ x = \"$x\", y = \"$y\", relative = false})"
fi
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.