Add screenshot script

main
furo 2023-08-09 17:59:18 +02:00
parent 23bfd45d52
commit f40eb6cf6e
1 changed files with 13 additions and 0 deletions

13
scripts/screenshot.sh Executable file
View File

@ -0,0 +1,13 @@
cd ~/Development/ddguesser
mkdir screenshots
ID=$(uuidgen)
MAP=$(dmenu < /dev/null)
if [ -z "$MAP" ]; then
exit 1
fi
ENTITIES=$(echo -e "false\ntrue" | dmenu)
mkdir screenshots
flameshot screen -p "./screenshots/$ID.png"
echo "INSERT INTO locations (id, map, has_entities) VALUES (\'$ID\', \'$MAP\', $ENTITIES);" >> inserts.psql