Code style violations: The arch enemy of maintainable code everywhere (Fixer CI)

Gilbert Pellegrom
Gilbert Pellegrom’s Blog
2 min readJun 16, 2017

Code style violations are the arch enemy of maintainable code everywhere. OK, I’m being a bit dramatic, but there is value to be had in everyone agreeing on, and following, a coding standard. There is a good reason every large project has one. They might vary wildly (e.g. the WordPress Coding Standard is pretty different from PHP’s PSR2 standard) but that’s ok. They key is that they have one at all. Why?

  • It makes code easier to scan (and grok)
  • It reduces cognitive friction
  • It keeps projects of any size consistent
  • It set’s expectations, making code easier to write
  • It improves the quality of the overall software system

In general it makes code easier to maintain, which in turn will reduce technical debt, make it easier to find bugs and ultimately make your software cost less to build.

Sure, your code will still “work” without following a coding standard. But the real question is, how easy will it be for the next developer who comes after you to understand the code you’ve written?

Have you ever come across any of the following situations?

  • You commit some code but have forgotten to check for code style violations
  • You’re doing a code review and are getting frustrated because you have to constantly highlight code style violations
  • You’re on-boarding a new dev and need to constantly pull them up for code style violations
  • You just want to enforce a coding standard across your entire team without having each dev set things up manually

If you’ve answered “yes” to any of these situations then you are in luck! My new project Fixer CI might be for you.

Fixer CI automatically fixes PHP code style violations by submitting Pull Requests (PR’s) to your GitHub repos that fix code style violations. It automatically detects pushes to your repos and fixes any code style violations (if there are any). It involves no setup, takes 2 mins to get up and running and can be customised to your needs.

If you’re interested in trying out Fixer CI you should head on over and sign up for an account just now. It’s completely free for public repos and sensibly priced for private projects depending on the needs of your team.

Fixer CI is in the very early stages at the moment so any feedback is much appreciated. If you want to have a chat hit me up on Twitter.

--

--

Gilbert Pellegrom
Gilbert Pellegrom’s Blog

Software Engineer from Scotland. Founder of @Dev7studioshq. Web Developer at @dliciousbrains.