PHPackages                             rlweb/phpcs-for-legacy - 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. rlweb/phpcs-for-legacy

ActiveLibrary

rlweb/phpcs-for-legacy
======================

Bring old codebases to new standards

v1.2(7y ago)017MITPHPPHP &gt;7

Since Jul 27Pushed 7y ago1 watchersCompare

[ Source](https://github.com/rlweb/phpcs-for-legacy)[ Packagist](https://packagist.org/packages/rlweb/phpcs-for-legacy)[ RSS](/packages/rlweb-phpcs-for-legacy/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (1)Dependencies (4)Versions (7)Used By (0)

PHPCS for Legacy codebases
==========================

[](#phpcs-for-legacy-codebases)

Can't get a monolitic code base up to scratch but would like incremental progress. PHPCS for legacy allows new standards to be implemented incrementally, by only enforcing them on new / edited code via checking the `git diff` output.

Install
-------

[](#install)

With composer simply `composer require -dev rlweb/phpcs-for-legacy`.

Usage
-----

[](#usage)

By running you initate the binary `vendor/bin/phpcslegacy run`

How it works
------------

[](#how-it-works)

- Firstly gets a output of `git diff head`
- Transforms the patch output into a useful array of `[filePath => [1,2,3,...]` to changed lines. For each changed line, we include the previous and the next line.
- Then it will run the PHPCS command against these files
- And then create a diff of the issues on the lines.

And output these only!

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity67

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

Total

6

Last Release

2841d ago

Major Versions

v0.0.1 → v1.02018-07-27

### Community

Maintainers

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

---

Top Contributors

[![rlweb](https://avatars.githubusercontent.com/u/173838?v=4)](https://github.com/rlweb "rlweb (11 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/rlweb-phpcs-for-legacy/health.svg)

```
[![Health](https://phpackages.com/badges/rlweb-phpcs-for-legacy/health.svg)](https://phpackages.com/packages/rlweb-phpcs-for-legacy)
```

###  Alternatives

[laravel/horizon

Dashboard and code-driven configuration for Laravel queues.

4.2k84.2M225](/packages/laravel-horizon)[drupal/core

Drupal is an open source content management platform powering millions of websites and applications.

19462.3M1.3k](/packages/drupal-core)[sulu/sulu

Core framework that implements the functionality of the Sulu content management system

1.3k1.3M152](/packages/sulu-sulu)[prestashop/prestashop

PrestaShop is an Open Source e-commerce platform, committed to providing the best shopping cart experience for both merchants and customers.

9.0k15.4k](/packages/prestashop-prestashop)[magento/magento2-functional-testing-framework

Magento2 Functional Testing Framework

15511.5M30](/packages/magento-magento2-functional-testing-framework)[spatie/laravel-export

Create a static site bundle from a Laravel app

646127.9k5](/packages/spatie-laravel-export)

PHPackages © 2026

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