addet scripts

This commit is contained in:
pika 2025-06-19 14:57:35 +02:00
parent 55101b6ba2
commit 9b3171425d
16 changed files with 25 additions and 9 deletions

14
scripts/screenshot Executable file
View file

@ -0,0 +1,14 @@
#!/usr/bin/env bash
# ─< Check if the given command exists silently >─────────────────────────────────────────
command_exists() {
command -v "$@" >/dev/null 2>&1
}
if command_exists hyprshot; then
notify-send -u low "screenshot" "Using hyprshot"
hyprshot --clipboard-only -m region
elif command_exists grim; then
notify-send -u low "screenshot" "Using grim"
grim -g "$(slurp)" -o $HOME/.config/screenshots/ - | wl-copy -t image/png
fi