/** * Execute the console command. * * @return void */ public function fire() { // get classes $classes = $this->finder->getClassesFromNamespace($this->config['routes_namespace']); // build metadata $routes = $this->scanner->scan($classes); // generate routes.php file for scanned routes $this->generator->generate($routes); $this->info('Routes registered successfully!'); }
/** * Execute the console command. * * @return void */ public function fire() { // delete routes.php file $this->generator->clean(); $this->info('Routes cleared successfully!'); }