PHPackages                             saschaegerer/arc-phpstan - 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. saschaegerer/arc-phpstan

Abandoned → [appsinet/arc-phpstan](/?search=appsinet%2Farc-phpstan)Library[Testing &amp; Quality](/categories/testing)

saschaegerer/arc-phpstan
========================

PHPStan linter for Phabricator's Arcanist

0.3.4(6y ago)02.1k[1 PRs](https://github.com/sascha-egerer/arc-phpstan/pulls)Apache-2.0PHP

Since Sep 18Pushed 1y ago1 watchersCompare

[ Source](https://github.com/sascha-egerer/arc-phpstan)[ Packagist](https://packagist.org/packages/saschaegerer/arc-phpstan)[ RSS](/packages/saschaegerer-arc-phpstan/feed)WikiDiscussions master Synced yesterday

READMEChangelog (5)Dependencies (1)Versions (10)Used By (0)

[![OSSAR](https://github.com/appsinet/arc-phpstan/workflows/OSSAR/badge.svg)](https://github.com/appsinet/arc-phpstan/workflows/OSSAR/badge.svg)

Based on [material-foundation/arc-tslint](https://github.com/material-foundation/arc-tslint) and some improvements made in [sascha-egerer/arc-phpstan](https://github.com/sascha-egerer/arc-phpstan). Provides basic support for `arc lint` to execute `phpstan`.

arc-phpstan
===========

[](#arc-phpstan)

Use [phpstan](https://github.com/phpstan/phpstan) to lint your PHP source code with [Phabricator](http://phabricator.org)'s `arc` command line tool.

Features
--------

[](#features)

phpstan generates warning messages.

Example output:

```
>>> Lint for src/AppBundle/Foo.php:

Error  () phpstan violation
Error: AppBundle\Foo::__construct() does not
call parent constructor from AppBundle\Bar.

          33      * constructor
          34      */
>>>       35     public function __construct()
          36     {
          37         Bar::__construct();
          38         $this->property = 0;

```

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

[](#installation)

phpstan is required. You can follow the [official instructions](https://github.com/phpstan/phpstan#installation) to install and put it on your $PATH, or you can run composer `install` and point the `bin` option to `vendor/bin/phpstan`, as in the example below.

### Project-specific installation

[](#project-specific-installation)

You can add this repository as a git submodule. Add a path to the submodule in your `.arcconfig`like so:

```
{
  "load": ["path/to/arc-phpstan"]
}
```

### Global installation

[](#global-installation)

`arcanist` can load modules from an absolute path. But it also searches for modules in a directory up one level from itself.

You can clone this repository to the same directory where `arcanist` and `libphutil` are located. In the end it will look like this:

```
arcanist/
arc-phpstan/
libphutil/
```

Your `.arcconfig` would look like

```
{
  "load": ["arc-phpstan"]
}
```

Setup
-----

[](#setup)

To use the linter you must register it in your `.arclint` file, as in this example

```
{
  "linters": {
    "phpstan": {
      "type": "phpstan",
      "include": "(\\.php$)",
      "config": "var/build/phpstan.neon", /* optional */
      "bin": "vendor/bin/phpstan", /* optional */
      "level": "0" /* optional */
    }
  }
}
```

License
-------

[](#license)

Licensed under the Apache 2.0 license. See LICENSE for details.

###  Health Score

31

—

LowBetter than 68% of packages

Maintenance29

Infrequent updates — may be unmaintained

Popularity15

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 Bus Factor2

2 contributors hold 50%+ of commits

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

Recently: every ~150 days

Total

7

Last Release

2491d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/8cab5b9422e572cf6a157fd040d217f3a8137bff045a8eae6fe42af51f13104d?d=identicon)[sascha.egerer](/maintainers/sascha.egerer)

---

Top Contributors

[![cmmata](https://avatars.githubusercontent.com/u/4223148?v=4)](https://github.com/cmmata "cmmata (14 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (11 commits)")[![marcorosello](https://avatars.githubusercontent.com/u/7166557?v=4)](https://github.com/marcorosello "marcorosello (3 commits)")[![sascha-egerer](https://avatars.githubusercontent.com/u/1651414?v=4)](https://github.com/sascha-egerer "sascha-egerer (2 commits)")[![integer](https://avatars.githubusercontent.com/u/160891?v=4)](https://github.com/integer "integer (2 commits)")[![krafas](https://avatars.githubusercontent.com/u/3889275?v=4)](https://github.com/krafas "krafas (1 commits)")[![magnetik](https://avatars.githubusercontent.com/u/345029?v=4)](https://github.com/magnetik "magnetik (1 commits)")

### Embed Badge

![Health badge](/badges/saschaegerer-arc-phpstan/health.svg)

```
[![Health](https://phpackages.com/badges/saschaegerer-arc-phpstan/health.svg)](https://phpackages.com/packages/saschaegerer-arc-phpstan)
```

###  Alternatives

[larastan/larastan

Larastan - Discover bugs in your code without running it. A phpstan/phpstan extension for Laravel

6.4k43.5M5.2k](/packages/larastan-larastan)[phpstan/phpstan-symfony

Symfony Framework extensions and rules for PHPStan

78268.9M1.5k](/packages/phpstan-phpstan-symfony)[phpstan/phpstan-doctrine

Doctrine extensions for PHPStan

66466.6M1.1k](/packages/phpstan-phpstan-doctrine)[phpat/phpat

PHP Architecture Tester

1.2k3.5M32](/packages/phpat-phpat)[spaze/phpstan-disallowed-calls

PHPStan rules to detect disallowed method &amp; function calls, constant, namespace, attribute, property &amp; superglobal usages, with powerful rules to re-allow a call or a usage in places where it should be allowed.

33120.0M375](/packages/spaze-phpstan-disallowed-calls)[mglaman/phpstan-drupal

Drupal extension and rules for PHPStan

20729.0M124](/packages/mglaman-phpstan-drupal)

PHPackages © 2026

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