https://github.com/guratr/nova-command-runner
Artisan commands runner for Laravel Nova
https://github.com/guratr/nova-command-runner
laravel nova package php vuejs
Last synced: 5 months ago
JSON representation
Artisan commands runner for Laravel Nova
- Host: GitHub
- URL: https://github.com/guratr/nova-command-runner
- Owner: guratr
- License: mit
- Created: 2019-01-07T22:02:56.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2020-10-21T09:36:46.000Z (over 4 years ago)
- Last Synced: 2024-09-28T18:01:27.048Z (9 months ago)
- Topics: laravel, nova, package, php, vuejs
- Language: Vue
- Homepage:
- Size: 21.5 KB
- Stars: 43
- Watchers: 4
- Forks: 4
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Laravel Nova tool for running Artisan commands.
[](https://packagist.org/packages/guratr/nova-command-runner)
[](https://packagist.org/packages/guratr/nova-command-runner)This [Nova](https://nova.laravel.com) tool lets you:
- run & queue artisan commands
- specify options for commands
- get command result
- view commands history
## Installation
You can install the nova tool in to a Laravel app that uses [Nova](https://nova.laravel.com) via composer:
```bash
composer require guratr/nova-command-runner
```Next up, you must register the tool with Nova. This is typically done in the `tools` method of the `NovaServiceProvider`.
```php
// in app/Providers/NovaServiceProvder.php// ...
public function tools()
{
return [
// ...
new \Guratr\CommandRunner\CommandRunner,
];
}
```Publish the config file:
``` bash
php artisan vendor:publish --provider="Guratr\CommandRunner\ToolServiceProvider"
```Add your commands to config/nova-command-runner.php
Available options:
- run : command to run (e.g. `route:cache`)
- options : array of options for command (e.g. `['--allow' => ['127.0.0.1']]`)
- queue : boolean (will use default settings when true) or array (e.g. `['connection' => 'database', 'queue' => 'default']`)
- type : button class (primary, secondary, success, danger, warning, info, light, dark, link)
- group: Group name (optional)## Usage
Click on the "Command Runner" menu item in your Nova app to see the tool.