mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-05 07:20:58 +08:00
MeiliSearch + Peers&Snatched table swip
This commit is contained in:
37
app/Console/Commands/MeiliSearchImport.php
Normal file
37
app/Console/Commands/MeiliSearchImport.php
Normal file
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
namespace App\Console\Commands;
|
||||
|
||||
use App\Repositories\MeiliSearchRepository;
|
||||
use Illuminate\Console\Command;
|
||||
|
||||
class MeiliSearchImport extends Command
|
||||
{
|
||||
/**
|
||||
* The name and signature of the console command.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $signature = 'meilisearch:import';
|
||||
|
||||
/**
|
||||
* The console command description.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $description = 'Command description';
|
||||
|
||||
/**
|
||||
* Execute the console command.
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function handle()
|
||||
{
|
||||
$rep = new MeiliSearchRepository();
|
||||
$this->info("going to import torrents");
|
||||
$total = $rep->import();
|
||||
$this->info("import $total torrents.");
|
||||
return Command::SUCCESS;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user