dotfiles/i3/screenshotter.sh
David Todd ac62357ba4 Add a screenshot uploader
This will take a screenshot (window or selection) and upload to
c0de.link/pics (link will be i.c0de.link/*, but other picture related
subdomains will go to the same place)
2019-03-05 03:23:38 -06:00

15 lines
297 B
Bash
Executable File

#!/bin/bash
DATE=$(date +%Y-%m-%d-%s).png
FILENAME=~/Pictures/$DATE
maim -s $FILENAME&
wait $!
notify-send "Uploading Screenshot"
scp $FILENAME web.foxnet.space:/var/www/c0de.link/pics&
wait $!
echo https://i.c0de.link/$DATE | xclip -selection clipboard
notify-send "Link copied to Clipboard"