SO i developed a custom package in Laravel 5.4, i add my route,my controllers but i have no idea how to add a artisan command, this is my code :
namespace MyPackage;
use Illuminate\Support\ServiceProvider;
class MyPackageServiceProvider extends ServiceProvider
{
/**
* Bootstrap the application services.
*
* @return void
*/
public function boot()
{
include __DIR__.'/routes.php';
}
/**
* Register the application services.
*
* @return void
*/
public function register()
{
$this->app->make('MyPackage\Controllers\MyPackageServiceController');
}
}
Normally in the usual case i add a new artisan command and add it to app/Console/Commands/Kernel.php, so how can i do that inside my package ?
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire