Today in awkward, convoluted solutions, I bring you the way I generated an index of all of my posts on this site. This is not one of those “look at this cool workflow” posts. This is an ugly thing, which wouldn’t be necessary if Squarespace flipped a couple of bits.
Like the rest of the things on my Squarespace wishlist, it doesn’t look like it’s happening anytime soon. So I went ahead and hacked this together. Here’s how I did it:
Exported the site to Wordpress format.
Edited the resultant XML file in TextMate, using a bunch of Regex find-and-replace to strip out everything apart from the
http://crateofpenguins.compart before every link.
linktags to markdown
[title](link)format using find-and-replace.
Converted Markdown to HTML and saved the file in Dropbox.
Set up an IFTTT rule like this one which adds a new file in my Dropbox folder with post details every time a new post gets added to the site.
Set up a Hazel rule which takes those IFTTT-generated files and prepends them to the main index file.
Include jQuery in the header and then include the contents of this file in the page header as well.
Add a code block to your page and put a
divinside it with an ID of
Published on August 23rd, 2013