musically coding

I’ve been in the WordPress plugin mindset all summer thanks to a bit of contract work, so finding myself with that metaphorical hammer and looking for some nails to pound on is not a surprising place to be.

In other words, I wrote myself another plugin.

Here’s the backstory.  I manage the website for an orchestra that I play in. I sit in the second violins, among about fifty other amateur musicians and we perform community concerts throughout the year. All of our music is distributed in the form of PDF parts behind a password protected page on a WordPress site. And up until this week there has been nothing particularly special about how I put the files up there, a method that generally includes uploading about fifteen to twenty parts and building a little link table for each piece.

It’s basic, and it generally works, but it is also quite time consuming and it would be a chore and a half to train someone else to do what I’m doing… not impossible, just lots of steps with some light HTML coding and managing metadata, yada yada.

I’ve been meaning to come up with a simpler way.

Vibe coding has helped enormously. AI can build out a starter framework and check for bugs in my code while I do the technical and UI design and refine the actual functionality and styles. 

What I built, then, was a new plugin called Sheet Music Librarian.

The new plugin makes heavy use of the content type functions in WordPress to build a new content type (Sheet Music) with (so far) a couple taxonomies supporting it (Instrument & Season). The content type handles the metadata for the piece, the season categorizes it by a set or season or collection, and the instrument allows each of the attached PDF files to be categorized by instrument.  It also has a key feature: bulk upload. So when our actual music librarian sends me three new pieces and sixty files to upload, I can just create those three Sheet Music records, upload twenty files at a time, use the drop down menu to flag the instrument on each, assign it to the right season collection and publish it. It all appears neatly in place on our site in about five minutes. So efficient. And probably pretty easy to train someone else to take over eventually.

On the front end the look is a bit different but mostly similar. The output is generated through a configurable shortcode and at the very top of each collection is a select menu with each of the first two nested layers of instrument categories so that any of the members can, say, pick their instrument and see just the files for their part.

I massaged the code with some extra help of the WordPress Checker plugin and uploaded for review last night.

You can check out the plugin and code repository on my plugin page.