September 6, 2012
Grilling 6253

Home 1672by Nick Curran

You don’t want to see the after.

October 19, 2011

I was looking to split a string on case changes today, and googling that problem didn’t turn up much. Here’s my implementation via a category. I hope it helps someone.

@interface NSString (Extensions)

- (NSString*) spacify;

@end

@implementation NSString (Extensions)

- (NSString*) spacify
{
    // ignore irrelevant strings
    if (self.length < 1)
        return self;
    
    NSMutableString* result = [NSMutableString stringWithString:self];
    
    // create a range starting after the first character
    NSRange range;
    range.location = 1;
    range.length = [self length] - 1;
    
    // match any uppercase character
    NSRegularExpression* r = [NSRegularExpression regularExpressionWithPattern: @"[A-Z]" 
                                                                       options: 0 
                                                                         error: nil];
    
    // replace matches with the match preceded by a space
    [r replaceMatchesInString: result 
                      options: 0 
                        range: range 
                 withTemplate: @" $0"];

    return [NSString stringWithString:result];
}

@end

September 11, 2011

Ever since I finished college and started working desk jobs, my weight has gone up gradually. For the first several years, this was a good thing. 5’10”, 145 lbs was not quite an attractive physique. When I hit 30, I was at 164 and pretty fit – exercising regularly.

By the end of last winter, I was at 187. I didn’t look that good and I didn’t feel that good. When my ultimate league started up in May, I couldn’t keep up with anyone. Shortly after that, I had my annual physical. I know BMI is a rough estimate at best, but the chart on the wall had me square in the middle of the overweight classification. When my blood work came back a week later, my cholesterol was (borderline) high for the first time. I was ashamed. I was also determined to turn it around.

I’ll save the suspense and report that by this weekend I’ve successfully lost 23 lbs. I’m back to 164, and I’m at least as fit as I was 7 years ago. This is how I did it, most of it is pretty basic:

  1. Eat Less – I really think this is the most important. At every meal I would consider what portion size I would have eaten. I then ate 50-75% as much. For example, I love Indian buffets. In the past I would typically take two or three trips. Now, I only take one.
  2. Exercise More – 45 minutes or more of exercise at least 6 days a week.
  3. Eat Better – I cut down on fried foods and sweets. My snacks were almost entirely fruit and nuts. More salads, very few appetizers.
  4. Punishment – Some of my favorite foods are french fries, potato chips, and buffalo wings. I love bacon and cheese on my hamburgers. I was ashamed of how far it had gotten, and I punished myself by vowing to eat absolutely no wings, fries or potato chips until I hit my goal. I could still eat hamburgers, but they were never with bacon and cheese. This also presents a nice little reward for reaching the goal: the punishment can stop.
  5. No Cheating – I stuck to the rules no matter what. It’s easy to say something’s a special occasion or to use a vacation as an excuse to take a break, but I think that’s highly counterproductive. A lot of people use exercise as an excuse to eat more. I didn’t.

I’m really happy with my progress here. Now that I’m at my goal, I intend to maintain the exercise level and better diet, while reducing the punishment as long as I stay under 165. While I don’t think I need to lose any weight, I would like to lower my body fat percentage. I feel a lot better, and I want that to continue.

August 30, 2011

I was first introduced to sailing when my father rented a Sunfish on Lake Phalen. My faded memory doesn’t recall a successful afternoon, but who knows? After that, I spent some time on his sailboards, and I always liked that while wanting for more control that my skinny teenaged body could muster.

A couple of summers ago, I took the sailing class offered by the Minneapolis Park & Rec board. That was a lot of fun as well as a good learning experience that I’d recommend to anyone. The same summer, a friend took me out on his catamaran on Mille Lacs Lake. We were cruising along pretty well, but found ourselves turtled in the very middle of the lake. The proper righting gear was not in place, and it seemed we might be stranded there all night. Not a boat was in site, and the middle of Mille Lacs is a long way from shore – not swimmable. We eventually recovered, but I have to admit it was scary.

Recovering from scary adventures is something I evidently enjoy, as I couldn’t wait to join the sailing club. After two and a half years dominated by grad school, I was excited by a summer free from school. Even better, I hired a lawn service. Looking for a fun way to fill that time, I’m really grateful that I found the Twin Cities Sailing Club.

The club is an awesome group for learning to sail and socializing with other like minded sailing enthusiasts. I’ve gone from being pretty green to “Skipper” status in the club: I can take out any of the clubs sixteen boats whenever I’d like. In return, I help other new sailors and join the club in maintenance days on top of a very reasonable membership free. It’s been great, and I look forward to many more summers spent sailing with them.

In the meantime, I’ve been enjoying a few adventures on my own. A couple of Fridays ago, I took a couple friends out on a C-Scow, a larger scow that I hadn’t previously skippered. I’d sailed the smaller MC-Scow many times, and this didn’t seem fundamentally different.

We enjoyed a few passes across the lake in lighter winds. In hopes of squeaking some more speed out of those slower winds, I asked my companions to sit on the leeward side of the boat to help us heel out of the water, reducing drag and letting us move faster. This was the key mistake on my part. An experienced crew would have been fine in that position, but once there it becomes very important to watch for coming gusts and shift weight accordingly.

A large gust came along pretty soon after that, and before they knew what was happening, the boat was on its side. I checked to make sure everyone was OK, and then reassured them that things were fine and that this happens from time to time. I’d done several capsize drills with the club, and I knew what to do in general. Unfortunately, I didn’t know what to do specifically for a scow. The capsize drills were all done on Catalina Capri 16.5s. The C-Scow is a different beast, and after a few attempts to right her, it was clear that I just didn’t know how.

A lot of helpful sailors turned up to give us a hand, but despite their best efforts we ended up swamping the boat. Around this time, I noticed some commotion at the nearby beach. There were, at least, one large firetruck, two police vehicles, and two ambulances waiting on shore along with a crowd. I saw this and said, “Oh man, tell me they’re not here for me.” Someone broke the news that they were. Despite our clear safety and the plenty of boats there to help us, someone on shore called 911, and the entire cavalry showed up. A police boat came out to meet us on the water, and there was another waiting on shore. They didn’t actually help us… just added to my mounting embarrassment.

In the end, a nice family helped us tow the boat to the beach where some club members and I were able to bail it out and get it seaworthy. I’m indebted to them and also to the experience as a whole. I learned a valuable lesson in crew assessment and scow handling in general, and we all walked away from it safely if a bit wetter than intended.

March 27, 2011

That’s a terrible blog post title, I know. Nevertheless, I just burned 90 minutes trying to figure out why a simple Spring MultiActionController setup left me with an error: “No request handling method with name ‘list’ in class.” Google was little help, so I resorted to Bing.

Eventually, I found a buried forum response with my exact problem, I had referenced the wrong package’s type! If you’re running in to this, make sure you do this:

import org.springframework.web.servlet.ModelAndView;

and not this:

import org.springframework.web.portlet.ModelAndView;

This will teach me to be more mindful of what Eclipse decides to add for me automatically.

March 2, 2011

The snow this year is driving me nuts. This is from the first of this season’s two “20-year” snowfalls, back when it was cool. Back when it could still possibly look pretty.

February 4, 2011
11:12 am | life | comment Mine!
Grilling 6253

Mine!by Nick Curran

Sharing is not really my strong suit, so I was excited when Ryan sent me this link to Ben & Jerry’s Pint Lock. A few shipping days later, and my ice cream stopped mysteriously disappearing.

August 15, 2010
8:21 pm | life | comment Escape

How Lemon escapesby Nick Curran

Not having wanted a dog in the first place, I was surprised by how hard I took our loss of Maeby last March. In her too-brief 22 months with us, she really endeared herself. She had tons of personality, and we will always miss her.

We adopted our new beagle, Lemon, in May – tomorrow marks three months. Hoping to have more years together this time around, we went with a younger dog – she’s probably about ten months old. As the video above shows, she can be a lot more challenging that Maeby was, but I think hope as she gets older, she’ll be just as fun.

January 16, 2010

File this under “Good Things to Know if You Own a Home”

Never store grass seed in plastic bags in your garage for the winter!

I took advantage of the today’s relative warmth by getting lots of stuff done around the house. Near the top of my list was cleaning the garage. I opened one of the cabinets above the workbench, and I was very confused to see grass seed, plant food and shredded paper all over the place. Even more confusing was all the crumpled up paper spilling out of my crumpled up leaf-blower bag. Very explanatory and startling was the mouse that popped its head out the bag to see where all that light was coming from.

When I finally went back and opened the cabinet again (with my golf club), several mice scampered off. I gave the leaf bag a few pokes with my pitching wedge, and even more ran out. I contemplated leaving it, but soon enough my to-do list was topped by “remove the mouse nest from my property.” I wish I had taken pictures, but the only thing on my mind was getting rid of that mess. It looked and smelled like an unmaintained hamster playground. Gross!

October 14, 2009

Pardon the relatively technical post, but I want to document this problem somewhere in hopes that it saves someone the frustration it caused me.

I’ve been experimenting with iPhone development lately. For the most part, it’s been a fun learning process despite the quirks that Xcode, IB, and Obj-C throw at an MS developer. Objective-C is, at worst, a 20-year-old hack that follows few conventions established by most other OO languagues.

My most recent lesson has been adapting my project to use Core Data for persistence. Early on, I kept receiving the error “message sectionOffset sent to freed object” when trying to load a connected table.

I found the solution nowhere online, and the exception is not at all helpful. For me, the problem was that I was trying to access the FetchedResultsController before performFetch had been called. Adding performFetch to my viewDidLoad fixed the issue, and I was on my way. My iPhone app is on its way.

February 3, 2009
3:58 pm | family | 2 comments After
Grilling 6253

Ben and Joe Afterfrom Big Sky 2009

It was a great trip. Fantastic weather, really good snow, no injuries, and my favorite part about Big Sky: no lift lines. The interns, as Ryan dubbed them, did really well. As predicted, I certainly had my work cut out for me just trying to keep up.

We got a lot of fun pictures too. Mine are here; Ryan’s are here. My favorite has to be this shot by Ryan. On the afternoon of the last day, we split up for a while. The boys headed to the terrain park while Ryan and I rode a couple blues we hadn’t seen yet. Our timing was perfect, because our next lift ride took us right over the park while Ben was making his run. He hit the C-box perfectly, and we were able to snap off some aerial photos. This all happened without any coordination.

I already can’t wait to go back, and the interns will be more than welcome when they’re ready for their true apprenticeship.

January 28, 2009
12:54 pm | family | 4 comments Before
Grilling 6253

Ben and Joe Beforefrom Winter 2003

I’ve always loved this picture, taken of my brothers Ben and Joe before their first snowboarding lesson. The total lack of enthusiasm on Joe’s face kills me. In 2003, I had the pleasure of teaching them how to ride. It was a struggle at first, but by the end of the day, they were both riding, turning, and stopping on their own, carving up the blues at Afton Alps. They’ve both become good riders, and I’m proud to have been a part of that.

Six years later, I feel very lucky to be able to bring them along to Big Sky this weekend. It’ll be their first exposure to real mountain snowboarding. I’m sure this time it’ll be me who struggles to keep up, and I’m hoping they’ll teach me a trick or two. My FS 270 needs work. This time, I’m assured that they’re very excited, and I hope to post a successful “After” picture soon.

November 15, 2008

I’m generally no fan of Apple. Their marketing is so frequently filled with lies. The Mac v. PC ads are impossibly smarmy. And the Apple Stores: the retail employees are either so uninformed or so blinded by corporate idolatry it makes me ill. (Don’t get me started on the so-called “genius” bar.)

Mac OS has its moments, but for every cool feature (Exposé, Spaces), there is as much awfulness (menu bar, Finder, window management, keyboard shortcuts). If you really think it’s any better than Vista, it’s probably time to put the Kool-Aid down. And the dev environment, Xcode? What a usability nightmare.

But I’ve certainly been a fan of their hardware ever since my 3rd-gen iPod. Their computers, phones, and media players are certainly the best looking around, and they always seem very solid. With that in mind, curious about iPhone development, and needing a laptop for grad school, I made the plunge and bought my first Mac – a refurbished MacBook Pro (MBP). This was in September.

Three weeks later, conveniently past the return period, Apple announced a new line of MBPs that were much cooler than mine. On top of that, mine started making a really high-pitched noise at medium brightness in Vista. Two separate repairs by the “geniuses” did nothing to fix the problem, and the laptop was beginning to show signs of having been taken apart and reassembled by non-experts.

Here I was seemingly stuck with an “obsolete” machine that made my ears ring and didn’t nearly shine like it had only six weeks ago.

So I was elated yesterday when I called Apple to pursue a third repair or possible exchange. After only a few minutes on the phone with customer service and a few more minutes on hold, they gave me an exception to the return policy – I’ll be getting a full refund for the “old” one. I was really impressed by this; kudos to Apple on a great “make good.” My new MBP is already on the way.

November 10, 2008

I had PRK surgery done two years ago, and my vision has been fantastic. I’ve generally been pretty comfortable, but every once in a while I’ll wake up in the middle of the night and my eyelids will be stuck to my eyes. Opening them quickly before I realize this is then very painful.

It happened again early Sunday morning and my right eye still stings today. I saw Dr. Croissant (his real name), and he explained that it’s not uncommon and nothing to worry about. I have a “recurrent abrasion.” My eyes are dry, and small areas of my cornea are not totally healed since the PRK procedure; this is normal. The dryness makes my lids stick to those healing parts of the cornea and then pull them off. I’ll be using a salve at night for a while to keep the eyes lubricated until they full heal.

November 8, 2008

Before I begin, let me clarify that I really enjoy Vista and Windows Media Center (WMC). Don’t let my recent purchases fool you, I haven’t become a Mac, and it doesn’t look like I’m going to. WMC combined with an Xbox 360 or other Media Center Extender (MCE) provides an awesome television viewing experience, especially in HD. With the issues ironed out, it’s been working fantastically for a couple of months now.

However, my experience with it hasn’t been without its problems. The problems themselves wouldn’t have been so bad if they had been well documented online, but they weren’t. This post exists so that hopefully someone else with the same problems can save themselves some of the swearing I’ve been reduced to.

My Setup

  • Windows Vista Ultimate
  • ASUS P5K Motherboard
  • Core 2 Quad – 2.4 Ghz
  • 4GB RAM (I only realize 3.25 under 32-bit Vista)
  • Seagate Barracuda 7200 rpm, 1TB Hard Drive
  • SiliconDust’s awesome HDHomeRun network TV tuner

Problem 1: Total Computer Freeze

I had used WMC on my old PC (and extended via the 360) without issue, so when I build the new box, I was pretty excited about seeing it all in HD. You can imagine my disappointment when I fired up the MCE on the 360 to try it out, seeing the great picture only to get an error message telling that WMC couldn’t connect. When I went to the PC to investigate, it was totally locked up. Not like a program had crashed… not like a blue screen… not rebooted… just totally frozen. Nothing to do but turn it off and back on.

This seemed to happen every time I used the extender. Sometimes it would happen immediately after the MCE started, usually it would happen 30 seconds or so in to watching something (live or recorded). Occasionally it would happen after 30 minutes or more of fine performance – this was the most frustrating, as it would seem that some tweaking I had tried had fixed the problem.

Solution: It turns out that this freezing has something to do with the onboard network card of my P5K motherboard, either the hardware itself or the drivers. Strangely, simply adding another network card did not fix the problem. I had to to remove the drivers completely and disable the card in the BIOS settings. After doing that and installing a new network card, this problem has gone away.

Problem 2: “application has launched UI unexpectedly”

I felt great when the total lockup was solved, but that didn’t last long. Soon enough I began to get the “application has launched UI unexpectedly” error from the 360 when trying to launch the MCE. I would reboot, and occasionally that would fix the problem. I also followed the steps in this Microsoft knowledge base article; that seemed to fix the problem too, until a week later when it happened again. Reapplied the steps, problem solved… until a week later when I was trying to demo my sweet setup to a friend… boom. This time reapplying the steps several times did nothing, and I was ready to beat my head against the wall when I saw the annoying “low battery warning” from my mouse driver pop up.

Solution: Duh – that was the unexpected UI! I checked the Startup folder for all users and sure enough, the mouse driver shortcut was there. When someone starts a MCE session, it runs as a separate user on the computer, logged on in the background. So that user was effectively getting the low battery warning with no way to handle them. I moved all the shortcuts from the “all users” startup folder and put them in my own startup folder, and I haven’t seen this happen since.

I hope this helps someone. If so, let me know!

July 30, 2008
2:32 pm | life | comment Summer
Grilling 6253

Lyric & Maebyfrom Grilling with Lyric

This sporadic blogger feels the need to post something, despite any specific news. So summer’s been going well. Our patio and grill have seen a lot of use with some thanks to Christin & Lyric and the Kesslers. Maeby’s been keeping us active, and both the dog and I are a few pounds lighter for it. I’ve been having a lot of fun with my new toy, my reading list, new things to study, and some old-school gaming.

My camera has been getting a lot of work as well, but a lot of that still sits on my computer awaiting “post-processing,” otherwise known as deleting, deleting, deleting, cropping, sharpening, and “I’m Feeling Lucky.” So when I finally get through that, there will be photos to enjoy of our continuing summer adventures, including grilling with the Bears, Minnesota wine country, and fun times at Lake Kjostad.

We also recently decided to take a long weekend in San Francisco. I’m excited to see it for the first time. If anyone has any travel tips for us, let me know.

February 26, 2008
3:01 pm | travel | comment Ride On
Twanny Flexes

Twanny Flexes from GLBT 2008

Finally got back on my snowboard for the first time in two years. Failing a real trip our west, Anthony and I spent last weekend tearing up Lutsen. I have low expectations of “the mountain” after my previous adventures there. I’ve been there at least three other times, during which I experienced mind-numbing cold (highs of -20), incredible warmth (for December – lows in the 40s), and pea-soup-thick fog (couldn’t see 30 feet in front of you).

As a result, I’ve never been able to experience what Lutsen has to offer. This trip was totally different. The snow was decent (although far from wonderful), and the weather was amazing. Not a cloud in the sky, no fog, no wind, and perfect temperatures – always between 12 and 15.

So it was nice to learn that one can actually have a good ride. There are lots of decent runs, and they’re just long enough to make it worth it. The lifts are slow, but the lift lines are quite short (especially if you can ride on a weekday). We were pleasantly sore after each day. Unfortunately, it felt like a good warm up for a trip to the Wasatch or Rockies, and it really made me miss snowboarding. The day after our trip I was just sad without it.

Incidentally, if you’re ever in Lutsen or near Grand Marais, I highly recommend dining at the Birch Terrace Supper Club. Delicious!

February 19, 2008

Carmen send me this incredibly weird, somewhat funny video/music tribute to my old home town. I’m still not sure what to think.

February 5, 2008

Wow, no posts in a month. What a terrible blogger I am. I think I’m justified this time. Frankly, January completely sucked. Hear now my saga.

On the Friday before New Year’s Eve, I woke with a terrible toothache. Despite it being her “busiest day of the year,” my dentist was nice enough squeeze me in. She determined that I needed a root canal. Yay! Unfortunately, she only had time to perform half a root canal – enough to alleviate my pain until the week after next when her schedule was more open.

That seemed to go fine until a couple of hours later – when the root canal got infected. I can’t describe how painful this was other than to say it felt like a kindey stone in my mouth (I’ve had kidney stones several times – it doesn’t get much worse). I called her emergency line, got her directly, and before too long I had some penicillin and was good as new.

Or was I? The Monday after I finished that course of antibiotics, I started to itch. I noticed two mosquito-bite sized bumps on my arm, and I couldn’t stop scratching them. By lunch time, there were three bumps. An hour or so later, there were eight. Hives! I realized that something was seriously wrong with me and went straight to the doctor. She determined that I was probably allergic to the penicillin. She told me to take Benedryll and gave me a perscription for a mild steroid in case they got worse.

I went home and rested, feeling comforted in my nice Benedryll haze, but by bedtime the hives were way, way worse. Imagine a five inch raised, red bump on your thigh that itches like nothing else. I had those in at least five or six spots on my body. Taking the steroid seemed to make them mostly go away by the next morning, and by Wednesday I could barely tell they had been there at all.

Feeling energized by that, I decided to finish the painting that I had started the weekend prior. I didn’t mind the work, and I sure liked the results: transforming the hideous aquarium-themed nursery into a nice, relaxing home office. I was painting without a mask, and with the doors and windows shut no less. It’s great how they’ve paint not smell bad anymore! Must be fine for you…

Or so I thought. The next morning, the hives were back worse than ever. Itching like crazy! Doc gave me a stronger steroid, and I had to take that and Benedryll for the next two weeks, leaving me in a terrible haze of dizziness, headache, and nausea – all mixed together with a strangely huge appetite. You’d think that’d be the end of it, but the hits just kept on coming. And this just raised a mystery: was I allergic to the penicillin or the paint?

Returning to the dentist to finish my root canal, I figured I might as well get my long-overdue schedule cleaning. In that process, they found two more deep cavities that “might also have to become root canals.” Great. Both had formed behind old fillings (like the first), so there was little I could have done about them. That evening, one of said fillings broke off, leaving a big scratchy hole in one side of my mouth to go along with the scratchy temporary crown on the other. Having the cavities filled in the end was actually more miserable than the root canal in the first place.

All that and I lost $65 at my first poker game of the year. I think I’m back to normal now, and I’m incredibly grateful for wonderful care. On the bright side, I have a great excuse to never paint again.

January 4, 2008

Here you go, “Baba.” While investigating used guitars on Craigslist for a coworker, I found this priceless listing:

I have an Oscar Schmidt 6-string acoustic guitar, Model# OG-2N. It is like new and in great condition. It was a gift from an ex, he was supposed to teach me how to play, but like every other part of our relationship, he was lazy. Also included is a molded SKB case, (price tag on it says $104.95), KORG chromatic tuner, and a lovely maroon-flowered strap. I am told that this is a great guitar for beginners, but honestly I really know nothing about it. I did a little ebay research and similar guitars are listed at this price…seems fair to me.

I can not provide you with a picture because I threw the camera at him during a fight. Maybe with your money I will buy a new one.

Please get this thing out of my house. Makes a great gift for the right girl, just not me, I wanted to learn the banjo.

Cash only please.

Cash only indeed.

December 6, 2007

After watching the fantastic An Inconvenient Truth over the weekend, it’s great to read news like this. I feel much safer knowing that the world’s scientists are leaving no stone unturned or animal’s anus unexplored in the search for global warming solutions.

November 10, 2007
5:05 pm | house | comment Sketchy

by Me

I’m addicted to SketchUp. It’s so much fun to play with, and I plan on actually putting it to some use. Phase one is to model the house’s first floor interior. Each room is a project waiting to happen, and this will make furniture purchase and layout much easier. I think it might help when we choose the color scheme for different rooms as well.

I’ve mentioned it before, but if you haven’t tried SketchUp, get on it. It’s free and incredibly “neat-o.”


November 8, 2007
2:09 pm | family | comment Hot Fuzz

by Me

Props to my cousin Matt “Fuzz” Letnes!

Wait, Fuzz?

Anyway… He and his friends write a Vikings blog for the USA Today, and today they are the featured blog on SportsScope.

It’s actually pretty funny, “Anytime the head coach has a moustache that is a dead ringer for Burt Reynolds’s ‘stache, you have to go with that team.” And wise, apparently.

Superbowl, Homeboy!


November 7, 2007
9:52 am | tech | comment Dreamhost

I’m moving TCOB to Dreamhost after experimenting with GoDaddy for several months. GoDaddy was fine, but it didn’t allow for as much technical experimentation. Furthermore, several of their processes seemed convoluted. I’m looking forward to trying out Subversion on Dreamhost as well. I’ll post again to this blog when everything seems moved.

October 31, 2007
10:11 am | funny | comment Bike Pride

Today’s post on Scott Adams’s blog is hilarious. It refers to this article in The Telegraph about a man caught and prosecuted for fornicating with a bicycle.

Yeah, that’s right.

What kills me about the article is the photo of the culprit. You’d expect a mug shot or a frantic paparazzi capture of a shamed man hiding from the press, right? Wrong. It almost looks like he hired a publicist and scheduled a photo shoot. He’s not hiding anything. I’m looking forward to showing my support for him at the one-man Bike Pride parade, certainly just around the corner.