PHPackages                             daydiff/yii2-unique-command - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. daydiff/yii2-unique-command

ActiveYii2-extension[Utility &amp; Helpers](/categories/utility)

daydiff/yii2-unique-command
===========================

Yii2 command trait and behavior allows you to control uniqueness of command

09PHP

Since Nov 7Pushed 9y agoCompare

[ Source](https://github.com/daydiff/yii2-unique-command)[ Packagist](https://packagist.org/packages/daydiff/yii2-unique-command)[ RSS](/packages/daydiff-yii2-unique-command/feed)WikiDiscussions master Synced yesterday

READMEChangelogDependenciesVersions (1)Used By (0)

Yii2 command behavior allows you to control uniqueness of a command
===================================================================

[](#yii2-command-behavior-allows-you-to-control-uniqueness-of-a-command)

How to use
----------

[](#how-to-use)

```
use Daydiff\UniqueCommand\UniqueCommandBehavior;
use yii\console\Controller;

class UniqueController extends Controller
{

    public function behaviors()
    {
        return [
            [
                'class' => UniqueCommandBehavior::className(),
                'actions' => ['foo'] //an action foo will be unique
            ]
        ];
    }

    /**
     * Unique action
     */
    public function actionFoo()
    {
        //just if it do really long work
        sleep(5);
        return 'unique';
    }

    /**
     * Non unique action
     */
    public function actionBar()
    {
        //just if it do really long work
        sleep(5);
        return 'non-unique';
    }
}
```

###  Health Score

20

—

LowBetter than 13% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 80% 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/2212845?v=4)[Aleksandr Tabakov](/maintainers/Daydiff)[@daydiff](https://github.com/daydiff)

---

Top Contributors

[![daydiff](https://avatars.githubusercontent.com/u/2212845?v=4)](https://github.com/daydiff "daydiff (4 commits)")[![elchroy](https://avatars.githubusercontent.com/u/17028608?v=4)](https://github.com/elchroy "elchroy (1 commits)")

### Embed Badge

![Health badge](/badges/daydiff-yii2-unique-command/health.svg)

```
[![Health](https://phpackages.com/badges/daydiff-yii2-unique-command/health.svg)](https://phpackages.com/packages/daydiff-yii2-unique-command)
```

###  Alternatives

[vendic/hyva-checkout-google-address-autocomplete

Hyvä checkout compatibility module for vendic/magento2-google-address-autocomplete

1436.0k1](/packages/vendic-hyva-checkout-google-address-autocomplete)

PHPackages © 2026

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