Goodbye, Middleman. Hello, Sculpin.

The first static site generator I worked with was Middleman. I was inspired by Julie Pagano’s Site Redesign Using Middleman. I will always be grateful to Julie for making the repository public at the time. It was a fantastic resource.

I was first introduced to Sculpin by Ashley Cyborski’s Fish Sticks: A Designer’s Adventure with Twig and Sculpin session at the very first MidCamp (Midwest Drupal Camp). And recently I attended Karl Kedrovsky’s Sculpin and Drupal session at DrupalCorn.

Middleman has a robust ecosystem, good documentation and a number of useful extensions. When I first looked at Sculpin’s documentation I did not feel very confident about migrating my site.

Why switch?

My motivation was centered around three goals:

  1. I want to learn Twig (which reminds me of Template Toolkit)
  2. I want to learn Symfony
  3. I want to get more comfortable with object oriented PHP

And since I like to one-up my challenges, I also decided to switch from using GitHub Pages to AWS S3 hosting.

After making a couple of missteps (created a bucket in the wrong region, waiting for DNS changes to take effect is like watching paint dry, brew install s3cmd) I finally got comfortable with publishing a barebones Sculpin-generated site to S3.

Learn by doing

Dissection is one of my favorite methods of learning. It is not the easiest path to proficiency, but exploring site source and pairing it with documentation is often the quickest way to orient oneself around a new technology.

My next step, then, was to find existing Sculpin sites and study them. I chose Beau Simensen’s beau.io and Gabriela D’Ávila’s gabriela.io as my dissection subjects.

The idea to use Clean Blog theme came from Etiene Dalcol’s etiene.net site.

I created a very simple favicon image (letter A in a red circle) and used Real Favicon Generator to generate a spiffy cross-platform favicon set.

Tip: If you are building a blog, the Sculpin Blog Skeleton is a good template to reference. I first created my own content type, only to run into problems later, when I tried to add tagging. Using the default posts content type solved the tag index problem for me.

To be continued…

There are still some mysteries for me to resolve:

  1. Markdown tables don’t render. With Middleman, I used the kramdown gem to render Markdown tables.
  2. Tag paths. How do I make tags like Drupal Planet to use lowercase paths with dashes?
  3. Aliases. middleman-alias gem allows you to create redirects. They are meta-refresh redirects, but still useful if you decide to change your site’s URL structure.
  4. Generators. How do I build my own?
  5. Extending Sculpin. What kind of bundle can I build?