PHPackages                             tightenco/tighten-coding-standard - 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. tightenco/tighten-coding-standard

Abandoned → [tightenco/duster](/?search=tightenco%2Fduster)ArchivedPhpcodesniffer-standard[Testing &amp; Quality](/categories/testing)

tightenco/tighten-coding-standard
=================================

A PHP Code\_Sniffer configuration for the Tighten coding standard.

v1.0.2(4y ago)14115.0k↓50%3MITPHPPHP ^7.3|^8.0

Since Feb 13Pushed 2y ago9 watchersCompare

[ Source](https://github.com/tighten/tighten-coding-standard)[ Packagist](https://packagist.org/packages/tightenco/tighten-coding-standard)[ Docs](https://github.com/tighten/tighten-coding-standard)[ RSS](/packages/tightenco-tighten-coding-standard/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (3)Dependencies (4)Versions (4)Used By (0)

Warning

**Tighten Coding Standard** has been archived. Please use **[Duster](https://github.com/tighten/duster)** instead.

PHP Coding Standard
===================

[](#php-coding-standard)

[![Latest Version on Packagist](https://camo.githubusercontent.com/b4f235ae26eed6758071c876c2e8bbd09fbd95d0a27007c285b2b3a698aec647/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f7469676874656e636f2f7469676874656e2d636f64696e672d7374616e646172642e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/tightenco/tighten-coding-standard)[![Run tests](https://github.com/tighten/tighten-coding-standard/workflows/Run%20tests/badge.svg?branch=main)](https://github.com/tighten/tighten-coding-standard/actions?query=workflow%3A%22Run+tests%22)

A PHP CodeSniffer configuration for the Tighten Coding Standard.

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

[](#installation)

You can install the package via composer:

```
composer require tightenco/tighten-coding-standard
```

Run `./vendor/bin/phpcs -i` to make sure you see "Tighten" in that list.

Usage
-----

[](#usage)

Add the standard to your local `.phpcs.xml.dist`:

```

   app
   config
   database
   public
   resources
   routes
   tests

```

Sniffs
------

[](#sniffs)

This list can be generated using:

```
./vendor/bin/phpcs --standard=Tighten -e
```

Documentation for a specific sniff can be generated using:

```
./vendor/bin/phpcs --generator=text --sniffs=Generic.Arrays.DisallowLongArraySyntax
```

### Generic (17 sniffs)

[](#generic-17-sniffs)

- Generic.Arrays.DisallowLongArraySyntax
- Generic.ControlStructures.InlineControlStructure
- Generic.Files.ByteOrderMark
- Generic.Files.LineEndings
- Generic.Files.LineLength
- Generic.Formatting.DisallowMultipleStatements
- Generic.Formatting.SpaceAfterNot
- Generic.Functions.FunctionCallArgumentSpacing
- Generic.NamingConventions.UpperCaseConstantName
- Generic.PHP.DisallowAlternativePHPTags
- Generic.PHP.DisallowShortOpenTag
- Generic.PHP.LowerCaseConstant
- Generic.PHP.LowerCaseKeyword
- Generic.PHP.LowerCaseType
- Generic.WhiteSpace.DisallowTabIndent
- Generic.WhiteSpace.IncrementDecrementSpacing
- Generic.WhiteSpace.ScopeIndent

### PEAR (1 sniff)

[](#pear-1-sniff)

- PEAR.Functions.ValidDefaultValue

### PSR1 (3 sniffs)

[](#psr1-3-sniffs)

- PSR1.Classes.ClassDeclaration
- PSR1.Files.SideEffects
- PSR1.Methods.CamelCapsMethodName

### PSR12 (16 sniffs)

[](#psr12-16-sniffs)

- PSR12.Classes.AnonClassDeclaration
- PSR12.Classes.ClassInstantiation
- PSR12.Classes.ClosingBrace
- PSR12.ControlStructures.BooleanOperatorPlacement
- PSR12.ControlStructures.ControlStructureSpacing
- PSR12.Files.DeclareStatement
- PSR12.Files.FileHeader
- PSR12.Files.ImportStatement
- PSR12.Files.OpenTag
- PSR12.Functions.NullableTypeDeclaration
- PSR12.Functions.ReturnTypeDeclaration
- PSR12.Keywords.ShortFormTypeKeywords
- PSR12.Namespaces.CompoundNamespaceDepth
- PSR12.Operators.OperatorSpacing
- PSR12.Properties.ConstantVisibility
- PSR12.Traits.UseDeclaration

### PSR2 (9 sniffs)

[](#psr2-9-sniffs)

- PSR2.Classes.ClassDeclaration
- PSR2.Classes.PropertyDeclaration
- PSR2.ControlStructures.ElseIfDeclaration
- PSR2.ControlStructures.SwitchDeclaration
- PSR2.Files.ClosingTag
- PSR2.Files.EndFileNewline
- PSR2.Methods.FunctionCallSignature
- PSR2.Methods.FunctionClosingBrace
- PSR2.Methods.MethodDeclaration

### Squiz (18 sniffs)

[](#squiz-18-sniffs)

- Squiz.Classes.ClassFileName
- Squiz.Classes.ValidClassName
- Squiz.ControlStructures.ControlSignature
- Squiz.ControlStructures.ForEachLoopDeclaration
- Squiz.ControlStructures.ForLoopDeclaration
- Squiz.ControlStructures.LowercaseDeclaration
- Squiz.Functions.FunctionDeclaration
- Squiz.Functions.FunctionDeclarationArgumentSpacing
- Squiz.Functions.LowercaseFunctionKeywords
- Squiz.Functions.MultiLineFunctionDeclaration
- Squiz.Scope.MethodScope
- Squiz.Strings.ConcatenationSpacing
- Squiz.Strings.DoubleQuoteUsage
- Squiz.WhiteSpace.CastSpacing
- Squiz.WhiteSpace.ControlStructureSpacing
- Squiz.WhiteSpace.ScopeClosingBrace
- Squiz.WhiteSpace.ScopeKeywordSpacing
- Squiz.WhiteSpace.SuperfluousWhitespace

Testing
-------

[](#testing)

```
composer test
```

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

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

Security
--------

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Sara Bine](https://github.com/sbine)
- [Matt Stauffer](https://github.com/mattstauffer)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

37

—

LowBetter than 83% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity38

Limited adoption so far

Community18

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor1

Top contributor holds 53.1% 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 ~93 days

Total

3

Last Release

1733d ago

PHP version history (3 changes)v1.0.0PHP ^7.4

v1.0.1PHP ^7.4|^8.0

v1.0.2PHP ^7.3|^8.0

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/151829?v=4)[Matt Stauffer](/maintainers/mattstauffer)[@mattstauffer](https://github.com/mattstauffer)

---

Top Contributors

[![mattstauffer](https://avatars.githubusercontent.com/u/151829?v=4)](https://github.com/mattstauffer "mattstauffer (17 commits)")[![driftingly](https://avatars.githubusercontent.com/u/194221?v=4)](https://github.com/driftingly "driftingly (8 commits)")[![jonsugar](https://avatars.githubusercontent.com/u/1974648?v=4)](https://github.com/jonsugar "jonsugar (3 commits)")[![faxblaster](https://avatars.githubusercontent.com/u/4378273?v=4)](https://github.com/faxblaster "faxblaster (2 commits)")[![peterhauke](https://avatars.githubusercontent.com/u/90506472?v=4)](https://github.com/peterhauke "peterhauke (1 commits)")[![sbine](https://avatars.githubusercontent.com/u/1902973?v=4)](https://github.com/sbine "sbine (1 commits)")

---

Tags

phptightencotighten-coding-standard

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/tightenco-tighten-coding-standard/health.svg)

```
[![Health](https://phpackages.com/badges/tightenco-tighten-coding-standard/health.svg)](https://phpackages.com/packages/tightenco-tighten-coding-standard)
```

###  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)[tightenco/duster

Automatic configuration for Laravel apps to apply Tighten's standard linting &amp; code standards.

5942.4M201](/packages/tightenco-duster)[youwe/testing-suite

Contains Youwe's default testing packages for php.

13176.9k8](/packages/youwe-testing-suite)

PHPackages © 2026

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