Created
April 7, 2014 17:08
-
-
Save cddr/10024258 to your computer and use it in GitHub Desktop.
Infinite selfie power
This file contains 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
# Lets thank Arnold for the headphones! | |
# | |
# Next time you're doing coding hours, get your headphones on and | |
# run this script in a terminal. | |
# | |
# Usage: | |
# | |
# 1. Download imagesnap from here: https://github.com/rharder/imagesnap | |
# 2. Update the global variables below according to where you put imagesnap | |
# and where you'd like the images to show up | |
# 3. We'll figure out how to assemble them later | |
OUTPUT=~/Pictures/coding-hours | |
IMAGESNAP_EXE=~/dev/imagesnap/imagesnap | |
DELAY=300 | |
mkdir -p $OUTPUT | |
function start { | |
while true; | |
do | |
$IMAGESNAP_EXE $OUTPUT/$(date +'%s').jpg | |
sleep $DELAY | |
done | |
} | |
echo "Starting selfied: Will take a photo every $DELAY seconds" | |
start | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment