PHPackages                             rubenvanerk/artisan-window - 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. rubenvanerk/artisan-window

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

rubenvanerk/artisan-window
==========================

A trait to create a fixed-size window in the Artisan console

0.1.0(3y ago)08[3 PRs](https://github.com/rubenvanerk/artisan-window/pulls)MITPHPPHP ^8.1

Since Mar 3Pushed 2y ago1 watchersCompare

[ Source](https://github.com/rubenvanerk/artisan-window)[ Packagist](https://packagist.org/packages/rubenvanerk/artisan-window)[ Docs](https://github.com/rubenvanerk/artisan-window)[ RSS](/packages/rubenvanerk-artisan-window/feed)WikiDiscussions main Synced today

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

A trait to create a fixed-size window in the Artisan console
============================================================

[](#a-trait-to-create-a-fixed-size-window-in-the-artisan-console)

[![Latest Version on Packagist](https://camo.githubusercontent.com/831ce142000334cda2b6286852257bf4f5a20bf1b696d33d433de49136936289/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f727562656e76616e65726b2f6172746973616e2d77696e646f772e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/rubenvanerk/artisan-window)[![GitHub Tests Action Status](https://camo.githubusercontent.com/ac245655f882daa44491d5e05d356b007931100c47051f81670719926d62294e/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f727562656e76616e65726b2f6172746973616e2d77696e646f772f72756e2d74657374732e796d6c3f6272616e63683d6d61696e266c6162656c3d7465737473267374796c653d666c61742d737175617265)](https://github.com/rubenvanerk/artisan-window/actions?query=workflow%3Arun-tests+branch%3Amain)[![GitHub Code Style Action Status](https://camo.githubusercontent.com/5439e30a89c5ab4c71a34a20b55a1567a04739ad67a505a8c4e3d4715df836cb/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f727562656e76616e65726b2f6172746973616e2d77696e646f772f6669782d7068702d636f64652d7374796c652d6973737565732e796d6c3f6272616e63683d6d61696e266c6162656c3d636f64652532307374796c65267374796c653d666c61742d737175617265)](https://github.com/rubenvanerk/artisan-window/actions?query=workflow%3A%22Fix+PHP+code+style+issues%22+branch%3Amain)[![Total Downloads](https://camo.githubusercontent.com/16ae55fa3f630fe5805a16499def5aafec8b7b062ce87c0b75d4ebacf063e77f/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f727562656e76616e65726b2f6172746973616e2d77696e646f772e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/rubenvanerk/artisan-window)

A simple trait to create a fixed-size Artisan console window.

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

[](#installation)

You can just copy the trait to your own project or install the package via composer:

```
composer require rubenvanerk/artisan-window
```

Usage
-----

[](#usage)

In your console command, add the `HasWindows` trait. Next, you can call the `window` function. It takes three arguments:

- The title of the window
- The max number of lines
- A function

In the function you can output anything you'd like. If the output doesn't fit, it will scroll out of the window.

```
class Example extends Command
{
    use \RubenVanErk\ArtisanWindow\Traits\HasWindows;

    public function handle()
    {
        $this->window('Never Gonna Give You Up', 5, function () {
            // ...
            $this->info('Never gonna give you up');
            $this->info('Never gonna let you down');
            $this->info('Never gonna run around and desert you');
            $this->info('Never gonna make you cry');
            $this->info('Never gonna say goodbye');
            $this->info('Never gonna tell a lie and hurt you');
            // ...
        })
    }
}
```

This wil produce something like this:

[![asciicast](https://camo.githubusercontent.com/6af013d4a019d6254f5324decabf22808d7553a795bc8fd2ea6a67a1660688db/68747470733a2f2f61736369696e656d612e6f72672f612f706769574a53395467566a75333339786e4466784f79634d352e737667)](https://asciinema.org/a/pgiWJS9TgVju339xnDfxOycM5)

```

## Testing

```bash
composer test

```

Changelog
---------

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.

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

[](#contributing)

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

Security Vulnerabilities
------------------------

[](#security-vulnerabilities)

Please review [our security policy](../../security/policy) on how to report security vulnerabilities.

Credits
-------

[](#credits)

- [Ruben van Erk](https://github.com/rubenvanerk)
- [All Contributors](../../contributors)

License
-------

[](#license)

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

###  Health Score

22

—

LowBetter than 21% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity47

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

Unknown

Total

1

Last Release

1218d ago

### Community

Maintainers

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

---

Top Contributors

[![rubenvanerk](https://avatars.githubusercontent.com/u/20305359?v=4)](https://github.com/rubenvanerk "rubenvanerk (8 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (5 commits)")[![github-actions[bot]](https://avatars.githubusercontent.com/in/15368?v=4)](https://github.com/github-actions[bot] "github-actions[bot] (5 commits)")

---

Tags

laravelrubenvanerkartisan-window

###  Code Quality

TestsPest

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/rubenvanerk-artisan-window/health.svg)

```
[![Health](https://phpackages.com/badges/rubenvanerk-artisan-window/health.svg)](https://phpackages.com/packages/rubenvanerk-artisan-window)
```

###  Alternatives

[spatie/laravel-permission

Permission handling for Laravel 12 and up

12.9k102.4M1.4k](/packages/spatie-laravel-permission)[spatie/laravel-health

Monitor the health of a Laravel application

87512.0M164](/packages/spatie-laravel-health)[spatie/laravel-pdf

Create PDFs in Laravel apps

1.0k4.8M47](/packages/spatie-laravel-pdf)[dedoc/scramble

Automatic generation of API documentation for Laravel applications.

2.1k11.2M100](/packages/dedoc-scramble)[illuminate/console

The Illuminate Console package.

13046.0M6.5k](/packages/illuminate-console)[worksome/exchange

Check Exchange Rates for any currency in Laravel.

124603.0k](/packages/worksome-exchange)

PHPackages © 2026

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