summaryrefslogtreecommitdiff
path: root/hypr/screenshotwayland.sh
blob: 73e2c6efa722ac1d0d34aa8492242cdb1acfbdad (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#!/bin/bash
input_type=$(printf "region\nwindow" | rofi -dmenu)
case "$input_type" in
  "window")
    hyprshot -m window --clipboard-only
    ;;
  *)
    hyprshot -m region --clipboard-only
    ;;
esac

choice=$(printf "save to clipboard\nsave to file" | rofi -dmenu)

case "$choice" in
  "save to file")
    wl-paste > ~/Pictures/Screenshots/screenshot-$(date +%F_%H-%M-%S).png
    ;;
  *)
    exit 0
    ;;
esac