aboutsummaryrefslogtreecommitdiffstats
path: root/config/hypr/scripts/ScreenShot.sh
diff options
context:
space:
mode:
authorJa.KooLit <jimmielovejay@gmail.com>2024-02-19 09:47:20 +0900
committerGitHub <noreply@github.com>2024-02-19 09:47:20 +0900
commit67c923b06dc4d005b81eab2a8cf8e941f84560b6 (patch)
tree0cb760313a52d6bccd93d66a58c55a71acc0a8d2 /config/hypr/scripts/ScreenShot.sh
parenta160ceeab550d8fdefc0b19f6b3a0dd6c2784db8 (diff)
parent4173c27eca72adb760178567c004e4c757c7b978 (diff)
Merge pull request #162 from JaKooLit/development
Development
Diffstat (limited to 'config/hypr/scripts/ScreenShot.sh')
-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