Posts

Showing posts from December, 2005

Egoless development

When you’re the only one you know working with a programming language it’s easy to ignore style. There’s no one to criticize anything so it’s easy to just focus on the problem at hand and use it to get the job done any old way you can. That’s the way I’ve always felt about working with Ruby, at least until now. I’ve used Ruby off and on since 2001 but I’ve never known anyone else interested in it. Also, I’ve only used it for small side projects so I’ve never developed great fluency. All of sudden now, though, it seems like the whole damn world is interested and I’m starting to think I need to hone up my Ruby skills. This includes trying to actually code like a 'Real' Ruby coder. So that was my mindset as I sat down last night to write a little chunk of Ruby code to process the comment file created by the PHP comment system I use in my blog. The file is called comments.txt and has a very simple format. Each line is a comment in the form: ID | DATA | TIME | NAME | EM

Giant Salmon - A short story

As I mentioned earlier, I've been trying to do more creative writing. Here's a very short story I recently finished. I hope you like it. Giant Salmon Why was the boat stopping? It wasn't supposed to stop. I had only jumped into the water because the boat would soon pull me up again and now it was stopping. Why did I let them talk me into this? I don't even like water skiing. Crap, they're taking the engine cover off. "Hey", I yell, hoping there's a serious problem and I wouldn't need to follow through with this. "It will just be a minute", the call comes back. I look down and see my legs and the water skis dangling above the darkness below. How deep is this really, I wonder; 15 feet, maybe, over my head for sure. Suddenly the image of shark looming up from the murky darkness flashes through my mind. Stop that, I scold myself as I mentally measure the distance to the boat and the nearest shore. I'm floating just about in

Ruby Honesty

In case you missed the opinion piece A little anti-anti-hype on O'Reilly Ruby it's worth a read. I found the following paragraphs particularity insightful: Pedantry: it's just how things work in the Python world. The status quo is always correct by definition. If you don't like something, you are incorrect. If you want to suggest a change, put in a PEP, Python's equivalent of Java's equally glacial JSR process. The Python FAQ goes to great lengths to rationalize a bunch of broken language features. They're obviously broken if they're frequently asked questions, but rather than 'fessing up and saying "we're planning on fixing this", they rationalize that the rest of the world just isn't thinking about the problem correctly. Every once in a while some broken feature is actually fixed (e.g. lexical scoping), and they say they changed it because people were "confused". Note that Python is never to blame. In contrast, Matz is

Importance of small things

I was reminded recently about how important small things can be in getting people to like your software. I've been a user of Bloglines for a long time but I've never really liked it. For some reason it just never clicked with me. That was until yesterday, when I found the option 'Show only updated feeds'. Now that I've enabled that little option, I love Bloglines. My list of blogs I'm watching seems small and manageable even though it's bigger than ever. It's amazing how a little things like this could change my whole relationship with the product. Food for thought.

Hyper-enthusiasts

I don't know if Bruce Eckel coined the term 'hyper-enthusiast' but his recent mention of it, in his Artima article , was the first time I heard it. He uses it to describe developers who extensively hype technology. It's a great phrase. I think it captures the essence of something I was acutely aware of but had never labeled.

Caganer Bush

Image
One of my first posts was about the Caganer, the Catalan Christmas figurine taking a poo (See Wikipedia ). Given the European opinion of President Bush, this years new model isn't really a surprise. It would probably sell well in nearly 50% of this country as well. Update: If you follow the Wikipedia link above, make sure you check out the Tio de Nadal Christmas tradition. Tio de Nadal is a tradition where kids care for a log for a few days and then on Christmas everyone beats the log with stick to encourage it to poops treats. I love old school, pagan traditions like this. It actually sounds fun.

10 Things Every Java Programmer Should Know About Ruby

Here's a nice concise presentation by Jim Weirich on the cool bits of Ruby. I love this part that demonstrates the message based behavior of Ruby. class VCR def initialize @messages = [] end def method_missing(method, *args, &block) @messages << [method, args, block] end def play_back_to(obj) @messages.each do |method, args, block| obj.send(method, *args, &block) end end end vcr = VCR.new vcr.sub!(/Java/) { "Ruby" } vcr.upcase! vcr[11,5] = "Universe" vcr << "!" string = "Hello Java World" puts string vcr.play_back_to(string) puts string This prints out: Hello Java World HELLO RUBY Universe! This is like nuke powered dynamic proxies . My brain swirls just thinking of the possibilities.

Patriots vs Colts

Watching the Patriots destroy the Buccaneers I'm starting to believe we actually have the ability to go into Indy in the playoffs and kick Manning's ass. There are a lot of games to play before then but if you had asked me a couple weeks ago, I wouldn't have thought it possible. Now, I'm smelling another Super Bowl. It's great being a Patriots fan.

How to lose your job

I can't set this clip up better than the web site I found it on ( wetasschronicles.com ) Approaching harbor is a bad time for a helmsman to fall asleep, or an officer of the watch to be in the head, or drunk, or whatever. In fact, here's what can happen: A vessel was due to arrive at a port in Spain at 0800 local time (LT). It would appear that at about 0600 LT the vessel contacted the Pilot Station confirming the ETA and was instructed to contact again some 20 minutes before arrival. At 07.59 hours LT, and despite the calls from the Traffic Control, the vessel grounded at full speed on the breakwater at the entrance to the port. A video, taken by surveillance cameras, shows "live" the sequence of the grounding, and needs no comments. Watch it--and cringe.... ( video link )

Selling Simple

Will simplicity ever sell? Currently it's a hook for grass roots engagement; but can it compete with the big guns of functionality, scalability and performance at the enterprise level?. Given its very real impact on total cost of ownership, it seems like it should. But how do sellers quantify simplicity into the TCO equation or use it counter claims of less than stellar performance? Searching the web for "TCO Simplicity" yields a lot of results so people are talking about it, but is it working? I know simplicity sells to some degree at the consumer level. My old employer, Alpha Software built itself on developing approachable products. You might think that the fact that most of you know of a product called 'Microsoft Access' but not of our product called ' Alpha Five ' invalidates this thesis, but I don't think so. How many small companies, that went head to head with MS in the 80's and 90's, are still around to talk about it? Not man

Wayfaring

Wayfaring is a cool website built with Ruby on Rails that lets you build topical maps using Google Maps technology. For example, I built this map of bars and restaurants in and around the Westford, and Littleton area of MA . Wayfaring is built for community editing so it will be neat to see how the map evolves, if at all. It's worth a look.

How to lose your job

I can't set this clip up better than the web site I found it on ( wetasschronicles.com ) Approaching harbor is a bad time for a helmsman to fall asleep, or an officer of the watch to be in the head, or drunk, or whatever. In fact, here's what can happen: A vessel was due to arrive at a port in Spain at 0800 local time (LT). It would appear that at about 0600 LT the vessel contacted the Pilot Station confirming the ETA and was instructed to contact again some 20 minutes before arrival. At 07.59 hours LT, and despite the calls from the Traffic Control, the vessel grounded at full speed on the breakwater at the entrance to the port. A video, taken by surveillance cameras, shows "live" the sequence of the grounding, and needs no comments. Watch it--and cringe.... ( video link )

Kubi in the news

While the Kubi development staff recently suffered a sad loss with the departure of Ned Batchelder , the company as a whole is starting to gain some traction and visibility in the CRM market place with our new product Kubi Enable . Here's a recent article from CRMguru.com that highlights Kubi as one of the new kids to watch. Kubi Software (Lincoln, Massachusetts). The basic premise of Kubi Software, and one that I agree with, is that while we would like all of the notes and communications associated with every sales opportunity to be kept in our CRM systems, the reality is they are not. Instead, they are far more often found in emails. For example, when a rep answers a prospect's question, negotiates with finance for a better price or strategizes with management on how to win the deal, he or she is more likely to store all that information in email, not the CRM system. Designed to be an extension of your existing CRM framework, Kubi organizes all those messages, priorities f

.NET headache - MeasureString

I've been working on a .Net custom control that displays a mix of text and graphics in a flow layout. The work required that I know the exact size of text strings in order to position the next widget relative to the previous string. .Net provides a method called MeasureString that you would think solves the problem but in fact it doesn't. MeasureString has the documented behavior of including 'a small amount of extra space before and after the string to allow for overhanging glyphs' ( link ). While I'm sure there was a good reason for doing this, it would seem prudent for MS to also give developers a straight forward way of knowing the actual size of the string. The help for MeasureString mentions that if you want to know the real size of the string you should use another method called MeasureCharacterRanges(). While MeasureCharacterRanges can provide the answer, calling it with the proper settings is not exactly obvious. I found a bunch of chatter out on the we

Deep sea template

Those of you not reading via RSS will see I've totally changed the look of the site. It's still a work in progress but It's close enough for now that I've posted it. I gave up on being table free and went for an easier to manage table based template. The right side border I made myself in paintshop pro 8. The actual sea creatures I clipped from a thumbnail of this poster . I did some blending and clipping to make the fit but the real hard work was done by illustrator Frank Walsh. I hope you all like it.

Built in Code Generation

I'm always looking for new ideas in programming languages. While looking at the Ferite language , I came across something I had never seen before; something the Ferite folks call a ' directive '. A directive lets you instruct the compiler to execute certain parts of the code at compile time in order to modify the existing code. It's like COG but built into the language. I don't know if the people behind Ferite came up with the idea themselves or if they borrowed this from another language, but regardless, It's the first time I've seen it. An example follows: class modifies Obj { directive access( ... ) { array a = arguments(); string code = "class modifies ${Class.name(self)} {"; Array.each( a ) using ( name ) { if( name isa string ) { code += " function set$name( void value ) { .$name = value; } function get$name() { return .$name; }"; } }; code += "}"; eval( code ); } }

Tailgate Shrimp

Here's a simple recipe I came up with for the Patriots game this weekend. It's spicy, quick and can pretty much all be eaten with just your fingers. It's perfect for tailgating Ingredients 1 Kielbasa Sausage 1 Chorizo Sausage 1 Onion 1 2lb. bag of uncooked frozen shrimp 1 Shaker of Cajun spice such as Emeril's Essence 1 Can/bottle beer Equipment 1 Tin foil pan 1 Knife 1 Tongs or a spoon 1 Grill I never have time to do any preparation before hand so this recipe is tailored to on site preparation. We actually stopped at the grocery store on the way to the game. You can do all the chopping and peeling ahead of time if you want. Preparation Start the grill. Chop the Kielbasa and Chorizo into 1 inch chunks (finger food size) and put into the tinfoil pan. Chop the onion into chunks and add. Put the tinfoil pan on the grill and spinkle in a heavy dose of Cajun seasoning. Let the sausage mixture cook until the onions are translucent and the sausage is hot. Now add a be

Envisioning a new language

In a new interview on SDN, Sun's Victoria Livschitz talks about her research language called Metaphors. This is 'pie in the sky', make your brain hurt, sort of stuff but there's some interesting ideas presented. Link

Try Ruby

You know you want to. Now it's easier than ever to take a quick peek and see what all the over-hyped fuss is about. Try Ruby is both an interactive Ruby shell and a very cool tutorial system. In the Ruby window type 'help' and just follow along. It's pretty damn slick.