Photog!

Installation Guide

Step 1 – Get Perl

“If you put a million monkeys at a million keyboards, one of them will eventually write a Java program. The rest of them will write Perl programs.”

Brian Kelly (source)

Photog! is written in the Perl programming language and will run on any system that has the Perl interpreter installed. Perl is installed by default on OS X and Linux, but Windows users will have to download and run an installer. You can check if Perl is installed by executing this command in a terminal:

perl -v

(On Windows, the terminal can be found at Accessories > Command Prompt. On OS X, the application is called “Terminal”. After starting the terminal, you can execute commands by typing them and pressing Enter.)

Step 2 – Get ImageMagick

ImageMagick is collection of command-line utilities to manipulate images. Photog! uses it to generate thumbnails and watermarks. It’s easiest to install ImageMagick using your operating system’s package manager, if you have one. On Debian-based operating systems, open a shell prompt and execute the following command:

sudo apt-get install imagemagick

On RedHat-based systems, use the following command:

sudo yum install ImageMagick

On OS X using Homebrew, use this command:

brew install imagemagick

Mac users without Homebrew and Windows users should use the ImageMagick installer.

Step 3 – Install Photog!

You are now ready for the final installation step: installing Photog! The installation command is the same on Windows, OS X, Linux, and any of the 100 platforms that Perl supports. In your terminal window, execute:

cpan Photography::Website

This command automatically downloads and installs Photog! from the Comprehensive Perl Archive Network (CPAN). During the installation process the cpan utility might ask you some questions. You can safely press Enter to accept the default answers.

Perl has an ecosystem with a heavy emphasis on the testing of software. The cpan command automatically downloads all the modules that Photog! depends on, and it runs all the tests that the authors of those modules have written. Sit back, relax, and enjoy the output of all the downloading, testing and installing. It might take a while.

When you get your prompt back without error messages, Photog! is successfully installed on your system. If the installation has failed, this is probably because one of the tests failed. You can work around this by instructing cpan to install anyway:

cpan -f -i Photography::Website

A note for Mac and Linux users: If you experience any problems, you can also try to install as root by prepending sudo to the installation command.

Creating your first website

Now Photog! has been installed, you’re ready to create your first photography website! Simply cd to your Pictures directory and execute photog:

cd Pictures
photog

Since this is your first run, Photog! will ask you what the destination directory should be. Press Enter to accept the default location. Now Photog! will start generating your website. When it’s done, look for a file named index.html in the destination directory and open it in your web browser. Enjoy!

Great! What Now?

The next step is to learn how you can configure Photog! to do exactly what you want. There are many configuration variables available. You can also customize the templates and the commands used to generate the images. You can even specify a seperate configuration for each subdirectory of your pictures folder. To learn how, head on over to the Documentation.