Last active
October 1, 2015 07:47
-
-
Save TheSkorm/1948756 to your computer and use it in GitHub Desktop.
Script to make a gallery in jukyll
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
exiftran -a -i -p * | |
mkdir thumbs | |
cp *.JPG thumbs | |
cp *.jpg thumbs | |
cp *.PNG thumbs | |
cp *.png thumbs | |
cd thumbs | |
mogrify -resize 100x * | |
cd .. | |
title=`pwd | sed 's/.*\///'` | |
echo "--- | |
layout: default | |
permalink: index.html | |
--- | |
$title | |
= | |
" > $title.markdown | |
for f in *.JPG; do echo "<a href=\"$f\" rel=\"lightbox[gal]\"><img alt=\"\" class=\"gallery\" src=\"thumbs/$f\"></a>" >> $title.markdown; done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment