I used to use WP-Syntax but I think this looks oh so nicer!
public class Hello { public static void main(String[] args) { System.out.println("Hello World!"); } }
Check it out at here.
I’ve recently moved to Firefox 3 on my MacBook Pro. The first thing I noticed was pretty much all of my Firefox plugins stopped working. This didn’t really bother me until I started developing on the laptop. The two things I really missed were Web Developer and FireBug.
After a little bit of googling, I was able to find other people with the same problem and fixes. While these are not official releases, they seem to be working just fine for me.
Check them out below:
“Do it to it” was a phrase that my high school computer science teacher would say after describing the next assignment he was giving the class.
The saying has following me throughout the years. Other than being a variation of Nike’s “Just Do it” motto, I’m not really sure why I still remember it other than it encompasses what really matters when being tasked with something.
Given two options of doing something myself or having someone else do it for me, I find myself often saying that I want to do it. I think it’s just that I want the experience and satisfaction (maybe I’m a control-freak). When it comes to work, I have always volunteered to try out new things or build the next big feature. That’s the fun stuff to work on. If there’s a really difficult problem or bug, although I am hating the bug when I’m trying to fix it, in retrospect I usually feel a sense of accomplishment and pride after fixing it.
I think that’s what a lot of programmers that have passion about code have in common. We really enjoy solving problems, using that brain of ours, and building new things with code. Between the late night deploys, emergency bug fixes, and ridiculous business requests, the challenge, the sense of ownership, and the art of building software makes it worthwhile and oh so enjoyable.
So, open up your favorite IDE and do it to it.
I’ve been trying out the newly released Rails 2.0. Lots of cool new stuff. However, it takes some time to get used to doing things the new way if you haven’t been working from EdgeRails.
One of the features that came out of the box in previous releases was support for autocomplete using scriptaculous. This has now been moved from the core rails install to an install via plugin.
Just install the plugin via:
script/plugin install http://svn.rubyonrails.org/rails/plugins/auto_complete
Then, you have to turn off the cross-site request forgery protection that comes with Rails 2.0.
You can do this at the Controller level by adding something similar to the following:
class UsersController < ApplicationController protect_from_forgery :only => [:update, :delete, :create] // exclude the auto_complete method ... end
If you don’t do this, your autocomplete actions will throw an ActionController::InvalidAuthenticityToken exception which caused me hours of confusion.
It’s been a very relaxing weekend. I spent most of my time plopped on the couch reading Eric Sink on the Business of the Software. The book is really just a collection of blog posts on Eric Sink’s blog but I enjoy holding a book rather than a laptop when reading for long periods of time. After reading countless technical books/blogs, it was extremely refreshing to read something like Sink’s book.
The book is split into four parts: entrepreneurship, people, marketing, and sales. The section that covers entrepreneurship reminds me of Guy Kawasaki’s The Art of the Start. The section on people covers the kind of people you want to work with and hire, which reminds me of Joel Spolsky’s recently released Smart and Gets Things Done. The section on marketing is what really made me enjoy this book. After reading Eric’s book, I have a newfound appreciation and a deeper understanding of the dark science known as marketing. He breaks it down and explains it from a developer’s perspective. The sales section is not surprising about how to get a potential customer to give you money for your software.
The book has a lot of insight into becoming ISV (Indepedent Software Vendor), more specifically a microISV. I think all software developers have pondered the what-ifs and wouldn’t-it-be-cool of starting their own software company. Very few make the jump. I would like to change that statistic.
After fighting apache for a couple hours, I finally have mongrel set up to proxy through apache.
At first I had the proxy module enabled but was getting a 403 page. After adding logging to the vhost config, I see
[Mon Sep 10 22:57:00 2007] [warn] proxy: No protocol handler was valid for the URL /. If you are using a DSO version of mod_proxy, make sure the proxy submodules are included in the configuration using LoadModule.
I go ahead and find out I didn’t have proxy_http enabled. After executing sudo a2enmod proxy_http
and bouncing apache, TA-DA!
I rebuilt my slice from scratch after screwing up my installations of ruby and rubygems. Good thing I had the WP-DB-Backup or else I would have lost all of my posts!
Yay! I got apache upgraded to 2.2 from 2.0. It was a lot easier after I was told by Aaron that Feisty has 2.2 in their apt-get repositories. I just had to update from Dapper to Feisty. Prior to updating I did have to comment out all of the repositories I had added to my /etc/apt/sources.list
. I was running into some broken wgets otherwise.
After commenting out the additional repository lines, I just followed the steps here and viola! apache2.2 comes up.
I did have to reinstall mod_jk for apache2.2 but that was a easy.
And the day is mine.
Well, I got to like the second step before I hit another roadblock. Looks like kodefoo’s repository only supports binary-i386 releases. Too bad my slice is on an AMD64 machine which means I need the amd64 release. I guess if I want to cluster mongrel with apache, I’ll have to compile from source. Sigh…
Prior to hitting this road block, I ran apt-get remove apache2
and it didn’t remove apache2 from my slice even though it said it did. So that’s a little confusing. I continued with the kodefoo tutorial regardless until I came across the problem noted above. I’ll eventually have to figure out how to do a clean remove of apache2.
At this point, I think I am just going to try to get a single mongrel served up through apache2. Hopefully, this will be easier…
Paul Graham just wrote a very insightful piece that I hope companies take note of. The start of the essay speaks to how important it is for programmers to have the ability to store the entire context of a problem in their head so they can navigate to all the pieces they need to work on. This is key for solving big problems and facilitates effective productivity. Graham goes on to provide 8 ways to help programmers to do this.
One of the ways he suggests is to work in small groups. At my work, we do a lot of pair programming and sometimes 3-way programming. I find this to be extremely effective for the way I code. I enjoy being able to constantly ask if this is the right way to approach a problem or am I understanding the problem correctly. With pair programming, I get immediate feedback by my teammate(s) and it helps to spread knowledge of the code base without having to go through code reviews.
The second half of the essay is what really inspired me to write this post. Graham makes the claim that companies deliberately try to do things wrong when it comes to dealing with programmers.
Graham writes:
One of the defining qualities of organizations since there have been such a thing is to treat individuals as interchangeable parts.
…
It’s not merely true that organizations dislike the idea of depending on individual genius, it’s a tautology. It’s part of the definition of an organization not to.
…
The weakest point in big companies is that they don’t let individual programmers do great work.
Moral of the story: Create a work environment where developers are truly valued. They are the problem solvers. They are the closest to the product. They are the ones bubbling with ideas. Listen to them. Don’t act like a big company no matter what your size is. This is how to beat your competitors.