By roger on Mar 02, 2010
Lets face it. It is a cut and paste world out there. I've been amazed at how many people seem to freeze when faced with a blank screen. "Where do I start?"
It seems our programming culture, for better or worse, has become one of programming by example. The internet has made so much code so easily available that its hard to think of something that doesn't have source code readily available. This is both good and bad. It's good because generally sharing makes the world a better place. You can make a lot more progress if you get to reuse other people's code. Many projects become integration projects rather than coding projects. You also get the benefit of seeing other people's code and learning from it - often a great experience. The bad side is that people rarely take the time to understand the code that they are using. This means that they end up with a system that they don't know well, and in complex systems this can lead to unstable or inefficient code.
Well, we aren't going to deny the power of sharing code. Its just too strong a force. After all the entire Sun SPOT project is open source because of this. We do believe that there is a benefit to learning a system with small bite-sized bits of code that are relatively easy to understand. With that in mind, we've created a tool just for sharing, storing and browsing snippets of Sun SPOT code. It can be found in the Sun SPOT Manager Tool under the new "Share" tab. David Simmons, who wrote this code, recently blogged about how to use it. Take a look and let us know what you think.