September 20, 2006
Coding Conventions: Make Them AgileSimple rules let your team deliver high-quality codeJason Mawdsley
Documented coding conventions take the pain out of development
Jason Mawdsley is a project leader and Certified ScrumMaster at Macadamian Technologies. You can reach him at jason@macadamian.com.
Quick--where's your coding convention document? What do you mean you don't know?
If you're like most developers, the coding convention document you were given when you started your job is in the bottom of a drawer somewhere or gathering dust on that top shelf, out of reach. Coding conventions are supposed to be useful tools for creating high quality code, but because they are rarely written by the developers themselves, coding conventions are often viewed as handcuffs shackling developer style and creativity.
This doesn't even take into account developers who work on multiple projects. Or do consulting work. If you do, you can find yourself having to learn different coding conventions several times a year.
The Complex Adaptive System
In Managing Agile Projects, Sanjiv Augustine says:
Development teams are a perfect example of a Complex Adaptive System. They're made up of technical, creative, highly intelligent, and autonomous developers interacting with each other in many ways.
Coding Conventions In the Complex Adaptive System
No wonder developers react badly to coding conventions, especially when they are imposed from higher up the food chain or are leftovers from a previous project. This kind of coding convention:
For it to be useful to a development team that matches the Complex Adaptive System criteria, a coding convention will have to consist of rules that are:
With these rules, emergent order comes from the team itself, rather then an external dominating force like a coding convention. These CASs are adaptive in that they react differently to different situations and environments, and evolve over the life of the project.
The Agile Coding Convention
Simple rules let your team deliver high-quality code as efficiently as possible. With this in mind, my agile coding convention consists of these simple rules:
|
|
||||||||||||||||||||||||||||||
|
|
|
|