As I've previously mentioned, software development is divided into two very distinct parts. The fun part that everyone loves, and the tedious bits that suck away your energy.
You can think of it like an iceberg. There's the top that everyone sees, where penguins frolic and hold parties. Then there's the sub-surface part. A dark and dreary place that people try to ignore. You can thank that part for the sinking of the titanic.
Today I'll be talking about the 90% you wish wasn't there. Sorry about that.
OK, so maybe it is, but if you're a programmer you'll know there's a certain satisfaction you can only get by automating some part of the development process. As Steve McConnell puts it in "Code Complete", if a programmer can do a job comfortably in five hours, or spend four hours and 45 minutes writing a tool to do it in 15 minutes, they'll choose to write the tool every time.
My tools directory is littered with quick, one off scripts I've written to get a job done, or other small applications I've downloaded. Today we'll be taking a brief look at my setup.
The language I use most frequently is Blitz Plus, so my development environment is tuned to making me more productive in it. My IDE of choice is Protean, which became a free product earlier this year.
The main reason I chose Protean was the excellent code completion support, as well as the project support. These two features alone have probably saved me hours worth of work. The standard Blitz IDE is a little clumsy for larger projects, and it was quite a hindrance.
I keep the Windows taskbar auto-minimised on the left of the screen. This helps when I have several windows open, and also maximises the amount of space the IDE gets. It's not a huge gain, but every little helps.
I also like the colour green.
My tools directory contains dozens of applications, ranging in size and complexity. There are far too many to list in detail here, so I'll stick to the ones I use most often.
- PHP – I use PHP for a lot of "glue" scripts, because it's quite easy to knock up a simple script to do something useful. My original build scripts were written in PHP, but I'm slowly migrating them to BlitzBuild. I've used PHP for all kinds of things, from generating code distributions to parsing source files for variables. I considered using Python for these tasks, but I felt more comfortable using PHP. It's not just for websites!
- pngcrush – A simple tool to compress png files a little further. Not really essential, but I'm still stuck in "this has to fit on a floppy" world so every saved byte counts.
- ResHacker – Blitz doesn't add much information to executables, so I use ResHacker to add a fancy exe icon, as well as resource information. It can be used from the command line, so it's part of my post-build script.
- Subversion – I run a Subversion server on another machine, and it's saved my bacon on several occasions. I use TortoiseSVN for the front end, because it makes life so much simpler.
- xsltproc – I've recently started using DocBook for documentation, and I use xsltproc to convert it into something pretty. I prefer running it on Linux, as it seems to run much faster.
- Kate – I use this for editing DocBook XML files, and it supports code completion and code folding. I sometimes dabble with XXE for DocBook work, but I find it to be overkill for most of the documents I work on.
As powerful as these tools are on their own, they really shine when joined together in a build script. At the moment, my Blitz projects have three batch files: "pre-build", "post-build" and "build-resources". The pre-build script is for auto-generating source files, and the post-build script takes care of adding resources to the exe and compressing it. The resource builder compresses sounds and graphics, processes any extra files (such as XML files that need converting) and creates all of the data files.
In the future, I want to move all of this into a single BlitzBuild script, as I feel the three batch files are a weak link in the build chain. I'd much rather run a single command and have the whole process work automatically, than run different batch files. I also want to add support for different configurations. This will allow for quick builds that don't create resources, as well as special debug builds that add extra information to the exe.
What tools do you use in your development process? Do you have any novel uses for existing tools? What single application saves you the most development time?