PHPackages                             helsingborg-stad/phpcs - 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. helsingborg-stad/phpcs

ActivePhpcodesniffer-standard

helsingborg-stad/phpcs
======================

PHP\_CodeSniffer rulesets supporting the coding standards for the Helsingborg Stad organization

0.3.5(2y ago)047.2k↓20%10ShellPHP &gt;=7.4

Since Dec 19Pushed 2y ago3 watchersCompare

[ Source](https://github.com/helsingborg-stad/phpcs)[ Packagist](https://packagist.org/packages/helsingborg-stad/phpcs)[ RSS](/packages/helsingborg-stad-phpcs/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (8)Dependencies (3)Versions (9)Used By (10)

PHP\_CodeSniffer rules for Helsingborg Stad
===========================================

[](#php_codesniffer-rules-for-helsingborg-stad)

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

[](#installation)

Run the following from the root of your project:

```
composer config allow-plugins.dealerdirect/phpcodesniffer-composer-installer true
composer require --dev helsingborg-stad/phpcs
```

Available rulesets
------------------

[](#available-rulesets)

### Hbg-WordPress

[](#hbg-wordpress)

Specific ruleset for WordPress themes and plugins.

#### Example Usage

[](#example-usage)

```

    ./source/php
    ./tests

```

Available composer binaries
---------------------------

[](#available-composer-binaries)

Included are 2 binaries for running phpcs and phpcbf on changed files only. The changes in the current branch are compared to supplied branch, and are meant to be used in a CI environment.

### Examples

[](#examples)

```
vendor/bin/phpcs-changed origin/main
```

This example runs phpcs on all changed files in the current branch compared to origin/main.

```
vendor/bin/phpcbf-changed origin/main
```

This example runs phpcbf on all changed files in the current branch compared to origin/main.

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity28

Limited adoption so far

Community17

Small or concentrated contributor base

Maturity37

Early-stage or recently created project

 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 ~6 days

Total

8

Last Release

841d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/f46fe64973c3e89d15c745c0bf601c25983bafea81d30e64d4bf813a6f8c8c7c?d=identicon)[sebastianthulin](/maintainers/sebastianthulin)

---

Top Contributors

[![thorbrink](https://avatars.githubusercontent.com/u/1064724?v=4)](https://github.com/thorbrink "thorbrink (12 commits)")

### Embed Badge

![Health badge](/badges/helsingborg-stad-phpcs/health.svg)

```
[![Health](https://phpackages.com/badges/helsingborg-stad-phpcs/health.svg)](https://phpackages.com/packages/helsingborg-stad-phpcs)
```

###  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)[drupal/coder

Coder is a library to review Drupal code.

3043.6M461](/packages/drupal-coder)[wp-cli/wp-cli-tests

WP-CLI testing framework

422.7M87](/packages/wp-cli-wp-cli-tests)[yoast/yoastcs

PHP\_CodeSniffer rules for Yoast projects

221.1M29](/packages/yoast-yoastcs)[mayflower/mo4-coding-standard

PHP CodeSniffer ruleset implementing the MO4 coding standards extending the Symfony coding standards.

17508.3k5](/packages/mayflower-mo4-coding-standard)[chromatic/usher

A collection of Robo commands for use on Chromatic projects.

13534.3k1](/packages/chromatic-usher)

PHPackages © 2026

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