Download the PHP package wilderborn/partyline without Composer
On this page you can find all versions of the php package wilderborn/partyline. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download wilderborn/partyline
More information about wilderborn/partyline
Files in wilderborn/partyline
Package partyline
Short Description A Laravel 5 package to output to the console from outside of command classes
License MIT
Informations about the package partyline
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:
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.
Facade usage
You can either use the globally aliased facade with a slash:
Or, you can import the facade:
Installation
This package can be installed through Composer.
For Laravel 5.4 and below, register the service provider and facade:
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.
More info on our Statamic blog: https://statamic.com/blog/partyline