Created
January 21, 2016 01:09
-
-
Save soramugi/0a04db213e541a219c96 to your computer and use it in GitHub Desktop.
Raspberry Piでカメラ接続して定点観測
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
DATE=`date "+%Y%m%d-%H%M%S"` | |
FILEDIR=/home/pi/observations | |
FILEPATH=$FILEDIR/$DATE.jpg | |
TMPFILE=/tmp/observation.jpg | |
raspistill -o $FILEPATH | |
find $FILEDIR/* -mtime +5 | xargs rm -f | |
convert -resize 520x -quality 100 $FILEPATH $TMPFILE | |
gyazo $TMPFILE | jq -r '.permalink_url, .url' | slack -c '#random' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment