PHPackages                             ardem/yii-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. [PSR &amp; Standards](/categories/psr-standards)
4. /
5. ardem/yii-coding-standard

ActiveLibrary[PSR &amp; Standards](/categories/psr-standards)

ardem/yii-coding-standard
=========================

Yii Framework PHP CodeSniffer Coding Standard.

377.2k↑125%13[3 issues](https://github.com/Ardem/yii-coding-standard/issues)[1 PRs](https://github.com/Ardem/yii-coding-standard/pulls)2PHP

Since Aug 6Pushed 10y ago9 watchersCompare

[ Source](https://github.com/Ardem/yii-coding-standard)[ Packagist](https://packagist.org/packages/ardem/yii-coding-standard)[ RSS](/packages/ardem-yii-coding-standard/feed)WikiDiscussions master Synced yesterday

READMEChangelogDependenciesVersions (1)Used By (2)

Yii Framework PHP CodeSniffer Coding Standard (official repo)
=============================================================

[](#yii-framework-php-codesniffer-coding-standard-official-repo)

You can read about Yii standard here:

How to install
--------------

[](#how-to-install)

1. Install PEAR:

    ```
     http://pear.php.net/manual/en/installation.getting.php

    ```
2. Install PHP\_CodeSniffer:

    ```
     pear install PHP_CodeSniffer

    ```
3. Install Yii Coding Standard:

    ```
     git clone git://github.com/Ardem/yii-coding-standard.git Yii
     sudo ln -sv /path/to/yii-coding-standard/Yii $(pear config-get php_dir)/PHP/CodeSniffer/Standards

    ```
4. If you want, you can set Yii as coding standard by default:

    ```
     phpcs --config-set default_standard Yii

    ```

How to make a simple test
-------------------------

[](#how-to-make-a-simple-test)

1. Checking a file (if yii-coding-standard is your standard by default)

    ```
     phpcs path/to/file.php

    ```
2. Checking a file (if yii-coding-standard is NOT your standard by default)

    ```
     phpcs --standard=Yii /path/to/file.php

    ```
3. Checking a directory (if yii-coding-standard is your standard by default)

    ```
     phpcs /path/to/directory

    ```
4. Checking a directory (if yii-coding-standard is NOT your standard by default)

    ```
     phpcs --standard=Yii /path/to/directory

    ```

How to use CS in IDE
--------------------

[](#how-to-use-cs-in-ide)

1. NetBeans:

    ```
     http://plugins.netbeans.org/plugin/40282/phpmd-php-codesniffer-plugin

    ```
2. PHPStorm

    ```
     http://www.jetbrains.com/phpstorm/webhelp/using-php-code-sniffer-tool.html

    ```
3. Zend Studio

    ```
     http://files.zend.com/help/Zend-Studio/content/working_with_php_codesniffer.htm

    ```

How to make a standard coding in the team
-----------------------------------------

[](#how-to-make-a-standard-coding-in-the-team)

Use pre-commit hooks, which will make a code standard check for every commit.

1. For Git

    ```
     http://git-scm.com/book/en/Customizing-Git-Git-Hooks

    ```
2. For SVN

    ```
     http://pear.php.net/manual/ru/package.php.php-codesniffer.svn-pre-commit.php

    ```

Yii-coding-standard and Composer
--------------------------------

[](#yii-coding-standard-and-composer)

For using "yii-coding-standard" with Composer, include a dependency for "ardem/yii-coding-standard" in your composer.json file:

```
    {
            "require": {
                    "ardem/yii-coding-standard": "dev-master"
            }
    }

```

###  Health Score

31

—

LowBetter than 66% of packages

Maintenance18

Infrequent updates — may be unmaintained

Popularity37

Limited adoption so far

Community18

Small or concentrated contributor base

Maturity41

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.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/346908?v=4)[ardem](/maintainers/ardem)[@Ardem](https://github.com/Ardem)

---

Top Contributors

[![Ardem](https://avatars.githubusercontent.com/u/346908?v=4)](https://github.com/Ardem "Ardem (25 commits)")

### Embed Badge

![Health badge](/badges/ardem-yii-coding-standard/health.svg)

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

###  Alternatives

[maclof/kubernetes-client

A simple yet elegant client for accessing and controlling a Kubernetes cluster.

237916.9k5](/packages/maclof-kubernetes-client)

PHPackages © 2026

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