What's Your Code Smell?

int MultiplyAndTransform(int x, int y, int z1) { int z2; if(x > 0) { z2 = 1; } else { z2 = -1; } return x * y + z2; } If you think that z1 should be omitted from the parameter list, then I would agree with you. Consesus shouldn't be assumed because, well, life. I characterized…

Immutable cordova dev machine for app builds

When a project needs some coding work, theres often platform configuration that gets in the way. This is especially true with cordova apps, where there is an application platform, build tools, and quite a few dependencies. Vagrant gives us a tool to configure the environment and commit it alongside our…

Javascript Logging with log4js

Logging isn't, or shouldn't be, a complicated thing, but for non-trivial projects, a significant amount of work can be done before giving any thought to logging. and debugging can be a struggle without good logging. I like log4j because of the flexibiliy of output options log4j-style api are usually available…

CrossFit Meets Data Science

I'm attending a data science meetup where people are hacking on their personal projects. Portia, the event organizer, welcomed me to the table. I met with Mary Anne working on her coursera homework for her data science class. Sheldon Kreger shared his personal project, drummerlist.com and gave me some…

MySQL on Raspberry Pi

MySQL on Raspberry Pi Get a sql server instance running quickly with a raspberry pi on a local network. First, install mysql via apt #install mysql sudo apt-get install mysql-server The installer allows you to set up your account. Then tweak the configuration to get access. I could connect immediately…

Editing .ppd files from the command line

I have a Polar CX800 heartrate/GPS tracking watch that I use when I go running. The software it uses is Polar ProTrainer 5, and its often useful to edit the raw data. Some of this can be done in the application, but I have been looking at the data…