PHPackages                             singular-it/php-codesniffer-base-config - 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. singular-it/php-codesniffer-base-config

ActiveLibrary

singular-it/php-codesniffer-base-config
=======================================

Base configuration for PHP Codesniffer

v1.0.2(3y ago)05

Since Apr 14Pushed 3y ago1 watchersCompare

[ Source](https://github.com/singularit-de/php-codesniffer-base-config)[ Packagist](https://packagist.org/packages/singular-it/php-codesniffer-base-config)[ RSS](/packages/singular-it-php-codesniffer-base-config/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (4)Used By (0)

PHP Codesniffer Base Config
===========================

[](#php-codesniffer-base-config)

Basic Information:
------------------

[](#basic-information)

### About the PHP Codesniffer Package:

[](#about-the-php-codesniffer-package)

PHP\_CodeSniffer is a set of two PHP scripts; the main phpcs script that tokenizes PHP, JavaScript and CSS files to detect violations of a defined coding standard, and a second phpcbf script to automatically correct coding standard violations. PHP\_CodeSniffer is an essential development tool that ensures your code remains clean and consistent.

=&gt; Documentation: [https://github.com/squizlabs/PHP\_CodeSniffer/wiki](https://github.com/squizlabs/PHP_CodeSniffer/wiki)

### About this Project:

[](#about-this-project)

This Project basically provides a set of predefined php coding standard rules that can be used and extended as described below.

Installation:
-------------

[](#installation)

1. Make the following additions to the composer.json file
    1. Add repository: ```
        "repositories": [
           {
              "type": "vcs",
              "url": "https://github.com/singularit-de/php-codesniffer-base-config.git"
           }
        ]
        ```
    2. Add the package: ```
        "require": {
           ...
           "singular-it/php-codesniffer-base-config": "dev-master"
           ...
        },
        ```
2. Run `composer install` or `composer update` to install the new dependency.
3. Create a file in your projects root directory called `phpcs.xml` with the following content: ```

        Project-specific ruleset

    ```

    Alternatively, for php versions smaller than 8, the rule should look like this: ``

CLI Usage:
----------

[](#cli-usage)

- You can now run phpcs via `vendor/bin/phpcs path/to/check` and are able to extend the phpcs.xml file to add project-specific rules.
- As PHP Codesniffer also includes the "PHP Code Beautifier and Fixer", you can use `vendor/bin/phpcbf path/to/fix` to automatically fix some smells.

PhpStorm Setup:
---------------

[](#phpstorm-setup)

Find the official description here:  . Basically:

- In the Settings under PHP &gt; Quality Tools &gt; PHP\_Codesniffer click on the three dots after the "Configuration"-field, which opens a separate view. Here you will find the "PHP\_CodeSniffer path" field and the "Path to phpcbf" field. The path to phpcs should be set to something like this `C:\...\vendor\bin\phpcs.bat` and the path to phpcbf to something like this `C:\...\vendor\bin\phpcbf.bat`.
- Go back to PHP &gt; Quality Tools &gt; PHP\_Codesniffer and choose "custom" as coding standard, which causes an input field to appear. If the option "custom" is not available, try closing and re-opening the settings. In this input field enter the path to your own phpcs.xml file in your project's root directory.
- Go to PHP &gt; Quality Tools &gt; External Formatters and code PHP Code Beautifier and Fixer.

=&gt; You should now be able to see IDE highlighting for code smells and hovering should give you the option to fix them, if they are automatically fixable.

###  Health Score

21

—

LowBetter than 18% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity47

Maturing project, gaining track record

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

Total

3

Last Release

1111d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/36a6690c2aa659b88f785375a84f4950dbd610421d057d93875a4dba9be2a992?d=identicon)[patrickK97](/maintainers/patrickK97)

---

Top Contributors

[![Lyshatt](https://avatars.githubusercontent.com/u/24221192?v=4)](https://github.com/Lyshatt "Lyshatt (15 commits)")

### Embed Badge

![Health badge](/badges/singular-it-php-codesniffer-base-config/health.svg)

```
[![Health](https://phpackages.com/badges/singular-it-php-codesniffer-base-config/health.svg)](https://phpackages.com/packages/singular-it-php-codesniffer-base-config)
```

PHPackages © 2026

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