#add git monitor
This commit is contained in:
@@ -11,8 +11,11 @@ class AppServiceProvider extends ServiceProvider
|
||||
*/
|
||||
public function register(): void
|
||||
{
|
||||
// 注册 JIRA 服务
|
||||
// 注册应用服务
|
||||
$this->app->singleton(\App\Services\JiraService::class);
|
||||
$this->app->singleton(\App\Services\ConfigService::class);
|
||||
$this->app->singleton(\App\Services\DingTalkService::class);
|
||||
$this->app->singleton(\App\Services\GitMonitorService::class);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
25
app/Providers/GitMonitorServiceProvider.php
Normal file
25
app/Providers/GitMonitorServiceProvider.php
Normal file
@@ -0,0 +1,25 @@
|
||||
<?php
|
||||
|
||||
namespace App\Providers;
|
||||
|
||||
use App\Console\Commands\GitMonitorCacheCommand;
|
||||
use App\Console\Commands\GitMonitorCheckCommand;
|
||||
use Illuminate\Support\ServiceProvider;
|
||||
|
||||
class GitMonitorServiceProvider extends ServiceProvider
|
||||
{
|
||||
public function register(): void
|
||||
{
|
||||
//
|
||||
}
|
||||
|
||||
public function boot(): void
|
||||
{
|
||||
if ($this->app->runningInConsole()) {
|
||||
$this->commands([
|
||||
GitMonitorCheckCommand::class,
|
||||
GitMonitorCacheCommand::class,
|
||||
]);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user