Automate your code quality control in 5 minutes!

Speaker(s)
Session track
Code & Development
Experience level
Intermediate
Duration
30 min

A session is focusing on code quality control and goes from simple to more complicated:

1. Defining the types of problems of the code

2. Evaluating its risks: psychological, reputational, time-related

3. Looking at the tools available to evaluate the code against the problems defined: PHP Lint, PHP Code Sniffer, PHP Mess Detector

4. Covering Drupal specifics of the task

5. Proposing a way to automate code quality control by tying together the mentioned tools with git workflow.

Often the code quality control task is performed as a part of Continuous Integration process. What if it is possible to do it one step earlier? How about saving human and processing time? The main point is how to easily integrate usage of the tools into daily routine of the development team by using git hooks. The session will be interesting for intermediate/advanced listeners (backend-developers), working both alone and in teams and looking for the way to optimize code quality control and ensure the same approach is used within the team.

Application quality is a cornerstone of software development and cannot be a negotiation point. Code quality control is really a "must have" both for agencies and individual/freelance software developers. After visiting the session the audience will have a practical guide how to setup the process of code control on three levels: syntax, code standards, structural on the very early period of "code lifecycle" - when trying to deliver the code to the repository. Such approach helps to identify the problems faster and learn from your own mistakes keeping the version control system clear. The session also include real-life examples and recommendations related specifically to Drupal and Drupal + composer.

Previous version of this session was presented at several local Drupal/PHP meetups in different countries (Minsk, Belarus and Tilburg, Netherlands), Drupal Europe and was met with enthusiasm and interest from the audience. One of the feedback messages received (on LinkedIn): "First of all i really enjoyed your talk about the code quality. This is something i've been trying to implement in the team but to no avail. Your technique sounds like something that could really work for me. I was wondering if you could share the githook you used in your presentation so i could furtherer implement this myself"

These words were an inspiration for future development of the topic, thus, to make configuration process as simple as possible, composer package was created to help development teams generate and install git hooks according to their needs in just a few minutes.

Slides