Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Partyline Laravel Package

wilderborn/partyline

Partyline adds lightweight, terminal-style feedback to your Laravel app. It helps you print and update messages, show progress, and display clean, interactive CLI output—handy for Artisan commands, long-running jobs, and scripts.

View on GitHub
Deep Wiki
Context7

Partyline

This package allows you to output to the console from outside of command class.

For example, you might have a feature that does the same thing from a command and through the web. Until now, you may have found yourself duplicating code just to be able to output to the console in various places.

With Partyline, you can use output commands within your logic. If it's being run inside the console, you'll see it. Otherwise, nothing will happen.

Usage

In your console command's handle method, bind the command into Partyline using the facade:

public function handle()
{
    \Partyline::bind($this);
}

Then in your regular classes, you may call any public Illuminate\Console\Command methods on the Partyline facade, just like you would inside the command class.

\Partyline::info('foo');
// Equivalent to $this->info('foo') within your command.

Facade usage

You can either use the globally aliased facade with a slash:

\Partyline::method();

Or, you can import the facade:

use Wilderborn\Partyline\Facade as Partyline;

Partyline::method();

Installation

This package can be installed through Composer.

composer require wilderborn/partyline

For Laravel 5.4 and below, register the service provider and facade:

// config/app.php
'providers' => [
    ...
    Wilderborn\Partyline\ServiceProvider::class,
    ...
],

'aliases' => [
    ...
    'Partyline' => Wilderborn\Partyline\Facade::class,
    ...
]

For Laravel 5.5+, this package will be automatically discovered.

Tips

If you have many commands classes, you may find it tedious to bind into Partyline every time. You may consider an abstract command class and bind inside the run method.

class YourCommand extends AbstractCommand
{
    public function handle()
    {
        //
    }
}
class AbstractCommand extends Command
{
    /**
     * Run the console command.
     *
     * @param  \Symfony\Component\Console\Input\InputInterface  $input
     * @param  \Symfony\Component\Console\Output\OutputInterface  $output
     * @return int
     */
    public function run(InputInterface $input, OutputInterface $output)
    {
        \Partyline::bind($this);

        return parent::run($input, $output);
    }
}

More info on our Statamic blog: https://statamic.com/blog/partyline

Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
davejamesmiller/laravel-breadcrumbs
artisanry/parsedown
christhompsontldr/phpsdk
enqueue/dsn
bunny/bunny
enqueue/test
enqueue/null
enqueue/amqp-tools
milesj/emojibase
bower-asset/punycode
bower-asset/inputmask
bower-asset/jquery
bower-asset/yii2-pjax
laravel/nova
spatie/laravel-mailcoach
spatie/laravel-superseeder
laravel/liferaft
nst/json-test-suite
danielmiessler/sec-lists
jackalope/jackalope-transport