PHPackages                             allapps2/shortcuts - 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. [CLI &amp; Console](/categories/cli)
4. /
5. allapps2/shortcuts

ActiveLibrary[CLI &amp; Console](/categories/cli)

allapps2/shortcuts
==================

Console shortcuts for sets of commands

2.1.0(11mo ago)026MITPHPPHP &gt;=8.2

Since Jun 20Pushed 11mo ago1 watchersCompare

[ Source](https://github.com/allapps2/shortcuts)[ Packagist](https://packagist.org/packages/allapps2/shortcuts)[ RSS](/packages/allapps2-shortcuts/feed)WikiDiscussions main Synced today

READMEChangelogDependenciesVersions (9)Used By (0)

shortcuts
=========

[](#shortcuts)

Console tool to call sets of commands using short aliases.

A distinctive feature is that it is configured entirely in **PHP**, which means accessibility of **code-completion**, finding of **usage**, using of your application **constants**, **validation** and actually brings the whole range of PHP possibilities and your IDE features.

The disadvantage of this is that the configuration is more verbose compared to YAML and other simple formats, but it is negligible compared to the benefits that the integration into the host application brings.

installation
------------

[](#installation)

### requirements

[](#requirements)

- PHP 8.2+
    php-cli package is enough (for example on Alpine Linux it can be installed by `apk add php82-cli`).

### download

[](#download)

download `short.phar` from and put it into your project (for example to .for-auto-completion folder to be used by your IDE like PhpStorm for code auto-completion).

### global install

[](#global-install)

to make `sc` alias available everywhere:

`sudo php short.phar install-global`

or any custom alias:

`sudo php short.phar install-global myalias`

usage
-----

[](#usage)

in folder with shortcuts.php:

`sc [ []]`

### example of shortcuts.php:

[](#example-of-shortcutsphp)

```
use Shortcuts\Command\CommandsCollection;
use Shortcuts\IBuilder;
use Shortcuts\Shortcut;
use Shortcuts\ShortcutArg;
use Shortcuts\ShortcutsCollection;
use Shortcuts\ShortcutsCollectionFactory;

class Shortcuts extends ShortcutsCollection
{
    function shortcut1(): CommandsCollection
    {
        return (new CommandsCollection)->add('long command1');
    }

    #[Shortcut(description: 'Shortcut description')]
    function shortcut2(
        string $requiredArgument,
        #[ShortcutArg(description: 'Optional argument')]
        string $optionalArgument = 'default value'
    ): CommandsCollection
    {
        return (new CommandsCollection)
            ->add('long command2 ' . $requiredArgument)
            ->add('long command3 ' . $optionalArgument);
    }
}

return new class implements IBuilder {
    function build(ShortcutsCollectionFactory $factory): ShortcutsCollection {
        return $factory->create(Shortcuts::class);
    }
};
```

for contributors
----------------

[](#for-contributors)

see [CONTRIBUTING.md](/CONTRIBUTING.md)

###  Health Score

33

—

LowBetter than 72% of packages

Maintenance52

Moderate activity, may be stable

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity58

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.

###  Release Activity

Cadence

Every ~58 days

Recently: every ~97 days

Total

8

Last Release

331d ago

Major Versions

1.4.1 → 2.0.02025-01-10

### Community

Maintainers

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

---

Top Contributors

[![allapps2](https://avatars.githubusercontent.com/u/152030297?v=4)](https://github.com/allapps2 "allapps2 (1 commits)")

### Embed Badge

![Health badge](/badges/allapps2-shortcuts/health.svg)

```
[![Health](https://phpackages.com/badges/allapps2-shortcuts/health.svg)](https://phpackages.com/packages/allapps2-shortcuts)
```

###  Alternatives

[illuminate/console

The Illuminate Console package.

13046.0M6.5k](/packages/illuminate-console)[styleci/cli

The CLI tool for StyleCI

71470.5k9](/packages/styleci-cli)[winbox/args

Windows command-line formatter

20720.9k21](/packages/winbox-args)[tomatophp/filament-artisan

Simple but yet powerful library for running some artisan commands for FilamentPHP

3275.4k1](/packages/tomatophp-filament-artisan)

PHPackages © 2026

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