mirror of
https://github.com/jikan-me/jikan-rest.git
synced 2025-02-20 11:23:35 +08:00
fixed media type choices and url for indexing
This commit is contained in:
parent
6c2d2d3e9d
commit
15bd63fdc7
@ -26,7 +26,7 @@ class IncrementalIndexer extends Command
|
||||
protected function promptForMissingArgumentsUsing(): array
|
||||
{
|
||||
return [
|
||||
'mediaType' => ['The media type to index.', 'Valid values: anime, manga, character, people']
|
||||
'mediaType' => ['The media type to index.', 'Valid values: anime, manga, characters, people']
|
||||
];
|
||||
}
|
||||
|
||||
@ -123,7 +123,7 @@ class IncrementalIndexer extends Command
|
||||
|
||||
$id = $ids[$index];
|
||||
|
||||
$url = env('APP_URL') . "/v4/anime/$id";
|
||||
$url = env('APP_URL') . "/v4/$mediaType/$id";
|
||||
$this->info("Indexing/Updating " . ($i + 1) . "/$idCount $url [MAL ID: $id]");
|
||||
|
||||
try
|
||||
@ -171,7 +171,7 @@ class IncrementalIndexer extends Command
|
||||
'failed' => $this->option('failed') ?? false
|
||||
],
|
||||
[
|
||||
'mediaType' => 'required|in:anime,manga,character,people',
|
||||
'mediaType' => 'required|in:anime,manga,characters,people',
|
||||
'delay' => 'integer|min:1',
|
||||
'resume' => 'bool|prohibited_with:failed',
|
||||
'failed' => 'bool|prohibited_with:resume'
|
||||
|
@ -34,7 +34,7 @@ display_help() {
|
||||
echo "stop Stop Jikan API"
|
||||
echo "validate-prereqs Validate pre-reqs installed (docker, docker-compose)"
|
||||
echo "execute-indexers Execute the indexers, which will scrape and index data from MAL. (Notice: This can take days)"
|
||||
echo "index-incrementally Executes the incremental indexers for each media type. (anime, manga, character, people)"
|
||||
echo "index-incrementally Executes the incremental indexers for each media type. (anime, manga, characters, people)"
|
||||
echo ""
|
||||
}
|
||||
|
||||
|
@ -39,7 +39,7 @@ start Start Jikan API (mongodb, typesense, redis, jikan-api wor
|
||||
stop Stop Jikan API
|
||||
validate-prereqs Validate pre-reqs installed (docker, docker-compose)
|
||||
execute-indexers Execute the indexers, which will scrape and index data from MAL. (Notice: This can take days)
|
||||
index-incrementally Executes the incremental indexers for each media type. (anime, manga, character, people)
|
||||
index-incrementally Executes the incremental indexers for each media type. (anime, manga, characters, people)
|
||||
```
|
||||
|
||||
### Running the indexer with the script
|
||||
|
Loading…
x
Reference in New Issue
Block a user