A few days ago I decided to bring my Middleman setup for this blog completely up-to-date with the freshest gems. So now I'm at Middleman 4.2. It was hard to get all of the supporting gems to work, and I had to leverage a couple of dicey forks, but . . . it all works. Along the way, though, my code for categorizing posts stopped working. This blog originated as a WordPress blog, and WordPress at some point introduced tags (they had only categories earlier). But Middleman Blog only knows tags. So when I ported my data over from WordPress, I wrote some code for Middleman so I could have categories there as well.
Here's how WordPress justifies having both categories and tags:
Once upon a time, WordPress.com only provided a Category option.
Categories allowed for a broad grouping of post topics, but when you wanted to describe a post in more specific terms, more categories were required. That led to very long category lists inside the blog and very long lists in Categories Widgets.
So we now have tags, too.
Tags are similar to categories, but they are generally used to describe your post in more detail. (https://en.support.wordpress.com/posts/categories-vs-tags/)
I think that makes sense: Categories for broad buckets / themes / channels, and tags to pick out details in the content for a particular post.
Anyway, I ported my code over to a Middleman extension. I also wrote it so that if you wanted to categorize your Middleman pages (not just blog articles) you can do it. I should probably write some specs and made it a little more amenable to other languages, but I think for now I'll see if anyone bothers to star or fork it.comments powered by Disqus