PHotoImporter Script

Like all people who own a Digital Camera and thus have gagilions of pictures from possibly several machines/ mobile phones / etc (webcams? Your absolute best Chatrollete face? :) ), I like to keep the whole thing organized on the filesystem . To facilitate this, I've written a very simple script that goes through a directory (say your memory card filled with pictures) reads the files and their EXIF information and then plants them on another directory (say your external hard drive?) with a date structure, followed by Camera brand and Camera Model (keeping the original name).

./2010-08-22/Canon/Canon EOS 10D

A directory example

I've had this for a long time but only now did I get around to put it up on GitHub, should it be useful to anyone (or for public shame) :) . It uses the Exifer Library to read the Exif information and all you need to run it is PHP (CLI) installed (You can probably get away with PHP4 - if you absolutely must) , it has the bare minimum of parameters and doesn't allow for much customization without changing the code, but if I'm putting it out there, I'm also making myself available for changes that might suit your need :)

You can Download it from GitHub and use it like this:

php PHotoImporter.php
**********************************************************************
** Script that organizes photo files acording to their EXIF tags
**
** -h --help            Help screen
** -r --recursive        Searches sub-directories for image files
** -s --source        Source path
** -d --destination    Destination Path
**
** Author : David Ramalho <dramalho [at] gmail [dot] com>
**
**********************************************************************