I don’t know about anyone else but I spend a good amount of time coding at home. It is nice because I get to drink beer and code at the same time. It is tough to do because I have all my home duties plus getting an hour or two to make something fun or learn somethings. I started to look at what I do at work to save time since “Time is Money” at work but “Time is Time” at home. Here is a quick list.
Source Control
It sounds simple enough but I looked over the times where I have blasted my code at home and spent a week restoring while a simple “svn revert” would have done the trick. For those who are worried about standing up a new server at home, don’t. There are many sites out there that will host your code for free. I keep all mine at darylmathisonblog.googlecode.com. A lot of these sites do this for open source only so if you are making the next best mousetrap, you should take the time and stand one up at your abode. Now all your changes are in one place that can be easily backed up by someone else or yourself.
Automated Testing
Automated testing is an investment in the future. In the beginning, it is a real pain to set up, then it becomes awesome time saver. With the click of a button tests that could have taken minutes to finish by hand are done in seconds. Unit tests can be combined and create test suites, now any change can be tested against the whole system or just that module. Automated test can run while you make dinner or put the kids to bed. The other neat thing, if you walk away from a project for a while the tests can give you an idea of how that module is supposed to run so you don’t spend a week of spare time figuring out your own code. Don’t forget to source control your automated tests too.
Use an IDE
An IDE (Integrated Development Environment) will pay back in the long run. When I am compiling, the error log created contains links to the offending code. When I create a new Java class, I use templates to initially set up the class. When I am starting up a new project, the IDE organizes it to make it easy to deploy. Good ones are expandable so I can create a tool to help me create a solution if one hasn’t been created already. I have been using Eclipse lately and the amount of add-ons it has blows me away. I can install servers on my computer and Eclipse will start up and shutdown the server as needed. It automatically builds source code so I know exactly where the code doesn’t compile before I do a test.
Well, there is my quick list. If you can think of anything else, post a comment.