Compare commits

...

3 Commits

Author SHA1 Message Date
Harzo 385106ccb0 dotfiles: Add patch for grimblast and update script 2023-06-10 12:32:56 +02:00
Harzo 1c7460de99 .gitignore: Ignore some dot directories 2023-06-10 12:32:22 +02:00
Harzo f700f7b3d2 swayidle: Use custom screenlock script 2023-06-09 14:58:31 +02:00
4 changed files with 37 additions and 2 deletions

View File

@ -1 +1 @@
timeout 300 'hyprctl dispatcher dpms off && swaylock'
timeout 300 'hyprctl dispatcher dpms off && ~/.local/bin/scripts/system/screenlock'

4
.gitignore vendored
View File

@ -10,16 +10,18 @@
.gnupg
.gtkrc-2.0
.hyprland
.java
.local/bin/*
.local/share/*
.local/state
.minecraft
.mozilla
.nv
.parallel
.pki
.profile
.pulse-cookie
.python_history
.python_*
.rustup
.ssh
.steam*

View File

@ -0,0 +1,7 @@
#!/bin/sh
CURDIR="$(dirname "$0")"
. "${CURDIR}/../helpers/root_guard.sh"
cp /usr/bin/grimblast ~/.local/bin/
patch -u ~/.local/bin/grimblast -i "${CURDIR}/../files/patches/grimblast-hide-cursor.patch"

View File

@ -0,0 +1,26 @@
--- /usr/bin/grimblast 2023-06-08 21:37:37.000000000 +0200
+++ ../../../../bin/grimblast 2023-06-09 14:42:41.857503879 +0200
@@ -131,6 +131,14 @@
FILE=$1
GEOM=$2
OUTPUT=$3
+
+ ORIG_POS="$(hyprctl cursorpos | tr -d ,)"
+ MONITOR="$(hyprctl monitors -j | jq -r '.[] | select(.focused == true).name')"
+ HEIGHT="$(hyprctl monitors -j | jq -r '.[] | select(.name == "'$MONITOR'").height')"
+ HEIGHT="$(echo "$HEIGHT - 1" | bc)"
+
+ hyprctl dispatch movecursor "0 $HEIGHT" > /dev/null
+
if [ -n "$OUTPUT" ]; then
grim ${CURSOR:+-c} -o "$OUTPUT" "$FILE" || die "Unable to invoke grim"
elif [ -z "$GEOM" ]; then
@@ -138,6 +146,8 @@
else
grim ${CURSOR:+-c} -g "$GEOM" "$FILE" || die "Unable to invoke grim"
fi
+
+ hyprctl dispatch movecursor "$ORIG_POS" > /dev/null
}
if [ "$ACTION" = "check" ]; then