sway-profiles/bin/sp-screenshot
2025-04-17 19:46:19 +00:00

13 lines
385 B
Bash
Executable file

#!/usr/bin/env bash
source "/usr/lib/sp-functions"
source "${conf_dir}/config"
op=$( echo -e "Output\nWindow\nRegion" | wofi -i --dmenu --width 250 --height 260 -k /dev/null | awk '{print tolower($1)}' )
echo "$op"
sleep 0.5
mkdir -p "${cache_dir}/screenshots/"
sway-screenshot -m $op --output-folder "${cache_dir}/screenshots/"
mv "${cache_dir}/screenshots/"* "${screenshot_dir}"