Archive for July 2011


Exercise and the Art of Christine Maintenance

July 10th, 2011 — 10:03pm

I’ve never been good at exercising regularly, despite lots of reminders, from many different sources, in various formats, explaining just how necessary exercise is for your { mental well-being, life span, quality of life, focus, self-image }. The last period of time in which I exercised regularly involved several very regimented systems (From Couch to 5KHundred Push-ups, and Groupon-spurred bikram yoga) and lasted for a total of about six weeks. This was a year ago. Before that, the last time I got regular exercise was the summer of 2006, during which I was interning in another city, and living with people who had much better habits than I.

After beginning a startup and doing very little between working and sleeping, I’ve finally (about six months in) reached a point where my schedule has stabilized a bit, and I’ve found a routine / set of incentives that I feel like I’ll be able to stick to for awhile – at least, I’ve followed it for the last seven weeks (one week longer than my last attempt) and am still going strong. I’m tired of having the phrase “disgustingly sedentary” float up in my mind when people ask me how I’ve been, and I’m looking forward to maintaining my newfound awesomeness. Below, the usual excuses I use to avoid working out, and how I’ve managed to skirt around them.

Typical Excuse #1: My schedule’s too fluid, and I can’t find time to exercise at the gym

My schedule is a bit eccentric, but once I discovered that I have a 24 Hour Fitness one block away from my office, I’ve found that I tend to come to a natural stopping point at around 1am each night. With a 24 hour gym, I can rarely find a reason to skip the gym before heading home. Plus points: I hate working out around other people, and there are rarely more than 3-4 other people at the gym between 1 and 4am (sometimes, I have the place all to myself!)

Typical Excuse #2: Cardio bores the pants off of me

My most successful stint at exercising regularly (summer of 2006) involved reading lots of Ayn Rand on a stationary bike, also late at night. I realized recently that, by bumping up the font size on my Kindle, I could easily read while running on a treadmill – and can now run for a previously unimaginably long time without noticing. (And then go for another 20-minute jog because I need to know what happens next!)

Typical Excuse #3: I know exercise is good for me, but man it’s such a time sink

When you’re running a startup, you work. A lot. And one of the things that I’ve lost (or have been unable to justify) as a result is my time to read for pleasure. By combining something that’s good for me and feels productive (cardio/gym) with something that makes me really happy and that I always want to do more of (reading for pleasure), I genuinely look forward to going to the gym and will often spend way more time exercising than I planned.

I was surprised at first with how much happier I’ve been as a result. I’m not sure if it’s actually the endorphins, or the “badass”-ness I feel from coming back to the office at 3am and sitting down for another hour or two of work (I mentioned my schedule was nutty), or finally being able to move books off my reading queue, but I’ve noticed a definite uptick in my mood and body image as a result. I’ve run something like 75 miles over the last six weeks (I make it to the gym an average of three times a week), and I’m looking forward to my numbers (I love you, Runkeeper!) going ever upward.

Comment » | personal

One-line HTTP server with Python

July 6th, 2011 — 4:39am

Most of the time, loading HTML files from the filesystem (with the file://localhost/Users/... sort of path in your URL bar) works fine – remote files are pulled in, Javascript can usually be run, and things are peachy.

Every once in awhile, though, you might run into a situation for which the file:// protocol is ill-suited — specifically, if/when you run into an error like this: Cross origin requests are only supported for HTTP.

In other words, I ran into this really cool snippet:


$ cd /home/somedir
$ python -m SimpleHTTPServer

… awhile ago, and needed it a couple of minutes ago, and could barely remember it (hat tip to LinuxJournal for being easily Googleable). So I’m posting it here for posterity, and to augment my clearly failing memory.

Running that command will make, by default, the index.html in /home/somedir accessible at http://localhost:8000.

Or you can pass in the preferred port (python -m SimpleHTTPServer 8080) into the command line instead.

Thumbs up. Onward!

* Also useful: tying this sort of thing to something like localtunnel, to brainlessly / painlessly broadcast something on your local machine to the interwebs.

Comment » | techy

Back to top