Search Icon, Magnifying Glass

Marmanold.com


Entries for #Post

The Magic Variable 'count'

So, I happened to be looking back through some old files and I found an early programming assignment from my first computer science course back in college. In the middle of the code I found this wonderful line:

while (cownt<years) {
    cout<<cownt+1; //"cownt" = "count", but when I entered it spelt correctly it gave me errors.//

As it turns out early on in the code I declared int cownt=0;. I either couldn’t find this typo in debugging my mere 61 lines of code or — what I think was actually going on — I thought count was a reserved magical variable that made loops work — not something I had to declare. Sometimes it’s nice to look back and see how far you’ve come.

Posted: , Words: ~200, Reading Time: 1 min

XML::Compile with an Extension Namespace

Starting this May, mortgage folk are going to be required to send Freddie and Fannie data including additional data points in ULDD phase 3 extension. At face value, adding these additional data points shouldn’t be a big deal at all. However, the legacy code I’m maintaining used XML::Compile to generate code. For various and sondry reasons — which I will not go into here — XML::Compile in the code I’m maintaining was in a place where it was extremely difficult to add XML elements that weren’t included in the original base Mismo 3.0 namespace.

Read more...

Posted: , Words: ~400, Reading Time: 2 min

Cron in Docker with Debian Slim

Recently, I needed to get cron working inside a Docker container running Debian Slim. It’s not difficult once you figure it out, but it did take a bit of research and learning to get everything to work.

First off, Debian Slim is real slim. There’s no cron nor is there a syslog when you want to debug things. Add apt-get install cron and rsyslog in your Dockerfile before you start anything else. With syslog installed, you can tail /var/log/syslog while you’re debugging your cron files, which is incredibly helpful.

Read more...

Posted: , Words: ~600, Reading Time: 3 min

Automated Weekly Sermon Podcast

Each Sunday at Church of the Epiphany we record our sermon using someone’s mobile phone. We started doing this back in September and, for the last three months, editing and uploading these sermons to our website has been a fairly manual process. Starting this month, however, with a combination of JustCast, Dropbox, Hazel, Squarespace, and Auphonic I’ve been able to mosty automate the process.


1. Download & Rename

Hazel Rule Renaming .m4a File

Each week shortly after worship, Fr. Justin e-mails me the audio recording of his sermon from his phone. His Android phone defaults to .m4a for audio, so I’ve setup a simple Hazel rule to monitor my download folder for that extension so the file is quickly renamed and moved off to my external archive drive.

Read more...

Posted: , Words: ~700, Reading Time: 4 min

Word to Markdown Conversion with Footnotes

Many of the essays on this site start their life in Microsoft Word or Scrivener. Early on, I would have to convert essays to Markdown for posting manually. This generally worked okay, but I lost my footnotes. I tried Word to Markdown for a brief while, but it didn’t work entirely as I’d like it to. Enter Pandoc. I’ve been using Pandoc to convert all of my Word documents — including footnotes — for the last two years. I’ve been delighted with the results.

Read more...

Posted: , Words: ~200, Reading Time: 1 min

East Nashville Antenna Television Update

Channel Master Smartenna 3000-HD Packaging

Almost a year ago I blogged about my new antenna set-up here in East Nashville. All in all, I’m still happy with my decision to drop cable and switch to antenna and streaming services. The Tivo Rovio OTA has proven to be money well spent. The Tivo is extremely easy to use and seamlessly binds OTA recordings with Hulu, Amazon Prime, and Netflix. Because the Tivo supports Plex, I’ve also converted an old Mac Mini into a Plex server. Our TiVo-centered over the air setup is better than cable ever was!

Read more...

Posted: , Words: ~400, Reading Time: 2 min