aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xconfig/hypr/scripts/ScreenShot.sh8
1 files changed, 7 insertions, 1 deletions
diff --git a/config/hypr/scripts/ScreenShot.sh b/config/hypr/scripts/ScreenShot.sh
index fa1b40ad..f35f9292 100755
--- a/config/hypr/scripts/ScreenShot.sh
+++ b/config/hypr/scripts/ScreenShot.sh
@@ -75,7 +75,13 @@ shotwin() {
}
shotarea() {
- cd ${dir} && grim -g "$(slurp)" - | tee "$file" | wl-copy
+ tmpfile=$(mktemp)
+ grim -g "$(slurp)" - >"$tmpfile"
+ if [[ -s "$tmpfile" ]]; then
+ wl-copy <"$tmpfile"
+ mv "$tmpfile" "$dir/$file"
+ fi
+ rm "$tmpfile"
notify_view
}
send patches to the email below
yukais@pinapelz.com
include the subject [PATCH repo_name]
pinapelz.com
homepage