We collaborate a lot at Blink Reaction. Not just internally, but with client development teams, our partners and, of course, the Drupal community.
Recently, a co-worker asked a question in our developer chat about the value of coding standards. He clearly understood it, however, the client he was working with was committing code to the sites git repo that was not in line with the (Drupal coding standards)[https://drupal.org/coding-standards]
The question he was asking, to paraphrase, was "How do I sell this client on the value of coding standards?"
We went around a bit, and came up with the following four:
- In many cases, YOU will be the developer looking at your own code in the future. You will also not remember what you were thinking when you wrote it. Keep the format to the standard so you don't have to waste time reformatting for readability when you can instead be focusing on the problem at hand.
- On average, code is probably read 1 or 2 orders of magnitude more frequently than it's written. Anything you can do to improve its structure pays future dividends every time it's read. (@ChipKaye)
- Coding standards are created by and adhered to by developers so we can easily read, understand, and modify each other's code. This is the nature of being a member of, and a contributor to, an open source community.
- Coding standards can be thought of as the lines and signs on the roads, we'd have a lot more accidents without them. (@WesRoepken)
We also found this awesome .gif which pretty much says it all...
http://i.imgur.com/1rQsggA.gif
In the end, we were able to convince the client that, while they're new to Drupal, the standards developed by the community are of value.
How do you sell the value of coding standards?