PHPackages                             nickwilde1990/php-composter-phpcs-drupal - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Testing &amp; Quality](/categories/testing)
4. /
5. nickwilde1990/php-composter-phpcs-drupal

ActivePhp-composter-action[Testing &amp; Quality](/categories/testing)

nickwilde1990/php-composter-phpcs-drupal
========================================

PHP Composter PHP Code Sniffer for Drupal (pre-commit).

2.0.0(7y ago)11.6kGPL-3.0-or-laterPHP

Since Sep 15Pushed 7y ago2 watchersCompare

[ Source](https://github.com/NickWilde1990/php-composter-phpcs-drupal)[ Packagist](https://packagist.org/packages/nickwilde1990/php-composter-phpcs-drupal)[ RSS](/packages/nickwilde1990-php-composter-phpcs-drupal/feed)WikiDiscussions master Synced 5d ago

READMEChangelogDependencies (4)Versions (3)Used By (0)

PHP Composter PHPCS Drupal
==========================

[](#php-composter-phpcs-drupal)

### Check your Drupal code for standards compliance before committing.

[](#check-your-drupal-code-for-standards-compliance-before-committing)

[![Latest Stable Version](https://camo.githubusercontent.com/16ea222109fd15f48a232189a27d9209def4312dcc32bbd6263aefe9540d2571/68747470733a2f2f706f7365722e707567782e6f72672f6e69636b77696c6465313939302f7068702d636f6d706f737465722d70687063732d64727570616c2f76657273696f6e)](https://packagist.org/packages/nickwilde1990/php-composter-phpcs-drupal)[![Total Downloads](https://camo.githubusercontent.com/a82c9fbc36586080bb637ca89a7d96cb4aaa37698361fcbc45c47eafe14af225/68747470733a2f2f706f7365722e707567782e6f72672f6e69636b77696c6465313939302f7068702d636f6d706f737465722d70687063732d64727570616c2f646f776e6c6f616473)](https://packagist.org/packages/nickwilde1990/php-composter-phpcs-drupal)[![Latest Unstable Version](https://camo.githubusercontent.com/5cc3d4481863b7355853d1ce546204326bdbd0757c3801ffb54a757c294dda9c/68747470733a2f2f706f7365722e707567782e6f72672f6e69636b77696c6465313939302f7068702d636f6d706f737465722d70687063732d64727570616c2f762f756e737461626c65)](https://packagist.org/packages/nickwilde1990/php-composter-phpcs-drupal)[![License](https://camo.githubusercontent.com/43de2e3b5e7d624f1de1874c1963b662cea758f254e320deaeb179b73843371a/68747470733a2f2f706f7365722e707567782e6f72672f6e69636b77696c6465313939302f7068702d636f6d706f737465722d70687063732d64727570616c2f6c6963656e7365)](https://packagist.org/packages/nickwilde1990/php-composter-phpcs-drupal)

This Composer package will enforce a check of your PHP files upon each commit to make sure they comply with the Drupal code standards as defined by [Drupal Coder](https://www.drupal.org/project/coder).

This is a [PHP Composter](https://github.com/php-composter/php-composter) Action.

Uses the wonderful [PHP CodeSniffer Project](https://github.com/squizlabs/PHP_CodeSniffer).

Table Of Contents
-----------------

[](#table-of-contents)

- [Installation](#installation)
- [Basic Usage](#basic-usage)
- [Configuration](#configuration)
- [Contributing](#contributing)

Installation
------------

[](#installation)

Just add as a development requirement to your `composer.json`, and it should work automagically:

```
composer require --dev nickwilde1990/php-composter-phpcs-drupal
```

**Note:** If you are using this with a Drupal module which is being run through the DrupalCI test bot, due to how that works/adds test dependencies, you will likely need to also run

```
composer require --dev "squizlabs/php_codesniffer:^3.3"
```

to force the required version of PHPCS since otherwise, the test bot is locked to the 2.8 branch.

Basic Usage
-----------

[](#basic-usage)

It should just work when you `git commit`.

Configuration
-------------

[](#configuration)

The [Drupal Coder](https://www.drupal.org/project/coder) module provides two sets of sniffs. By default this uses the `Drupal` sniff rather than `DrupalPractice`. If you want to use `DrupalPractice` (or any other sniff set), you can specify that standard to use in your composer.json's `extra` key:

```
 "extra": {
   "php-composter-phpcs-drupal": {
     "standard": "DrupalPractice"
   }
 }
```

Contributing
------------

[](#contributing)

All feedback / bug reports / pull requests are welcome.

###  Health Score

30

—

LowBetter than 64% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity17

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity63

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~12 days

Total

2

Last Release

2789d ago

Major Versions

1.0.0 → 2.0.02018-09-27

### Community

Maintainers

![](https://www.gravatar.com/avatar/335bc60327415dda3c2e3e00708c02f10938b263d8e3740748d11b80f4333127?d=identicon)[NickWilde1990](/maintainers/NickWilde1990)

---

Top Contributors

[![NickDickinsonWilde](https://avatars.githubusercontent.com/u/92694?v=4)](https://github.com/NickDickinsonWilde "NickDickinsonWilde (3 commits)")

### Embed Badge

![Health badge](/badges/nickwilde1990-php-composter-phpcs-drupal/health.svg)

```
[![Health](https://phpackages.com/badges/nickwilde1990-php-composter-phpcs-drupal/health.svg)](https://phpackages.com/packages/nickwilde1990-php-composter-phpcs-drupal)
```

###  Alternatives

[slevomat/coding-standard

Slevomat Coding Standard for PHP\_CodeSniffer complements Consistence Coding Standard by providing sniffs with additional checks.

1.5k123.5M1.8k](/packages/slevomat-coding-standard)[axelerant/drupal-quality-checker

Code quality checking tools for Drupal project.

13197.9k1](/packages/axelerant-drupal-quality-checker)[youwe/testing-suite

Contains Youwe's default testing packages for php.

13176.9k8](/packages/youwe-testing-suite)[moodlehq/moodle-cs

Moodle Coding Sniffer rules

242.8M5](/packages/moodlehq-moodle-cs)[acquia/orca

A tool for testing a company's software packages together in the context of a realistic, functioning, best practices Drupal build

32902.4k](/packages/acquia-orca)[vijaycs85/drupal-quality-checker

Setups code quality checking tools for Drupal project.

52192.3k4](/packages/vijaycs85-drupal-quality-checker)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
