Skip to content

Commit

Permalink
Merge pull request #11519 from nanaya/command-load
Browse files Browse the repository at this point in the history
Simplify artisan commands init
  • Loading branch information
notbakaneko authored Sep 30, 2024
2 parents 73fa1bf + 376ba08 commit 8084252
Showing 1 changed file with 5 additions and 79 deletions.
84 changes: 5 additions & 79 deletions app/Console/Kernel.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,81 +10,12 @@

class Kernel extends ConsoleKernel
{
/**
* The Artisan commands provided by your application.
*
* @var array
*/
protected $commands = [
Commands\DbCreate::class,
Commands\DbSetup::class,

Commands\EsCreateSearchBlacklist::class,
Commands\EsIndexDocuments::class,
Commands\EsIndexScoresQueue::class,
Commands\EsIndexScoresSetSchema::class,
Commands\EsIndexWiki::class,

Commands\Ip2AsnUpdate::class,

// modding stuff
Commands\ModdingRankCommand::class,

Commands\UserForumStatSyncCommand::class,
Commands\BeatmapsetsHypeSyncCommand::class,
Commands\BeatmapsetNominationSyncCommand::class,

Commands\StoreCleanupStaleOrders::class,
Commands\StoreExpireProducts::class,
Commands\StoreGetPaypalOrder::class,
Commands\StoreGetShopifyCheckout::class,

// builds
Commands\BuildsCreate::class,
Commands\BuildsUpdatePropagationHistory::class,

// forum
Commands\ForumTopicCoversCleanup::class,

// leaderboard recalculation
Commands\RankingsRecalculateCountryStats::class,

// moddingv2 kudosu recalculation
Commands\KudosuRecalculateDiscussionsGrants::class,

// fix username change fail :D
Commands\FixUsernameChangeTopicCache::class,

// fix userchannel deletion fail
Commands\FixMissingUserChannels::class,

// fix forum display order
Commands\FixForumDisplayOrder::class,

Commands\MigrateFreshAllCommand::class,
Commands\MigrateFreshOrRunCommand::class,

Commands\NotificationsSendMail::class,

Commands\OAuthDeleteExpiredTokens::class,

Commands\RouteConvert::class,

Commands\UserBestScoresCheckCommand::class,
Commands\UserRecalculateRankCounts::class,

Commands\UserNotificationsCleanup::class,
Commands\NotificationsCleanup::class,

Commands\ChatExpireAck::class,
Commands\ChatChannelSetLastMessageId::class,

Commands\BeatmapLeadersRefresh::class,
protected function commands(): void
{
$this->load(__DIR__.'/Commands');

Commands\DailyChallengeCreateNext::class,
Commands\DailyChallengeUserStatsCalculate::class,
Commands\DailyChallengeUserStatsRecalculate::class,
];
require base_path('routes/console.php');
}

/**
* Define the application's command schedule.
Expand Down Expand Up @@ -152,9 +83,4 @@ protected function schedule(Schedule $schedule)
->cron('10 0 * * *')
->onOneServer();
}

protected function commands()
{
require base_path('routes/console.php');
}
}

0 comments on commit 8084252

Please sign in to comment.