Create routes file.

@return void
496452
protected function createRoutesFile()
    {
        $file = $this->directory.'/routes.php';

        $contents = $this->getStub('routes');
        $this->laravel['files']->put($file, str_replace('DummyNamespace', config('admin.route.namespace'), $contents));
        $this->line('<info>Routes file was created:</info> '.str_replace(base_path(), '', $file));
    }
563285
protected function createDirectoryIfNotExists()
    {
        if (!is_dir($this->getPath())) {
            $this->files->makeDirectory($this->getPath(), 0755, true);
        }
    }
784102
public function setup()
    {
        $this->groupRoutes();

        foreach ($this->routes as $type => $routes) {
            foreach ($routes as $name => $route) {
                $newRoute = new Route($name, $route);
                if (!$newRoute->hasParam('hostname')) {
                    $newRoute->setParam('hostname', $this->resolveDefaultHostName());
                }

                $routeType = $this->resolveRouteType($type);
                $routeType->add($this->getRouter(), $newRoute);
            }
        }
    }
255943
protected function registerCustomRoutes()
    {
        if (file_exists($file = $this->getBootstrapPath('routes.php'))) {
            $this->registerRoutes(function (Router $route) use ($file) {
                require $file;
            });
        }
    }
634657
protected function addAppRoutes()
    {
        $routes = $this->getConfig('routes');
        if (is_array($routes)) {
            $this->getRouter()->addRoutes($routes);
        }
    }
225814
public function setupRoutes()
    {
        foreach ($this->paths as $oldPath => &$newPath) {
            $this->addRedirection($oldPath, $newPath);
        }
    }
300396
public function includeRoutesFiles()
	{
		// Application Specific Module Route File Locations
		if(Config::get('sorad.api.routes.file') && is_array(Config::get('sorad.api.routes.file')))
		{
			foreach(Config::get('sorad.api.routes.file') as $route)
			{
				// Check if is an app directory and use default routes file name.
				if(is_dir(app_path($route)))
				{
					$this->loadRoutesFrom(app_path($route . '/' . $this->getRouteFileName()));
				}
				elseif(is_file(app_path($route)))
				{
					$this->loadRoutesFrom(app_path($route));
				}
			}
		}
	}
793132
public function route()
    {
        global $logger;
        try {
            // TODO : Refactor Code :
            // $url    = URLParser::parse();
            // $route  = RouteMapper::getRoute($url['route']);
            // $router = new Router();
            // $router->route($route);
            $urlInterpreter = new UrlInterpreter();
            $command        = $urlInterpreter->getCommand();
            $router         = new Router($command);
            $logger->debug('Routing to : '.$command->getControllerName());
            $router->route();
        } catch (Exception $e) {
            throw new RouteNotFoundException();	
        }
    }
316802
public function createAuthController()
    {
        $authController = $this->directory.'/Controllers/AuthController.php';
        $contents = $this->getStub('AuthController');

        $this->laravel['files']->put(
            $authController,
            str_replace('DummyNamespace', config('admin.route.namespace'), $contents)
        );
        $this->line('<info>AuthController file was created:</info> '.str_replace(base_path(), '', $authController));
    }
400133
private function createRoutes()
    {
        $this->routeCollection->add('_content', new Route('/{slug}', [
            '_controller' => 'OpiferContentBundle:Frontend/Content:view',
            'slug'        => '',
        ], [
            'slug'        => "[a-zA-Z0-9\-_\/]*",
        ], [
            'expose'      => true,
        ]));
        $this->routeCollection->add('home', new Route('/', [
            '_controller' => 'OpiferContentBundle:Frontend/Content:view',
            'slug'        => '',
        ], [
            'slug'        => "[a-zA-Z0-9\-_\/]*",
        ], [
            'expose'      => true,
        ]));
    }
358529
public function route()
    {
        $this->dashboardRouting($this->relativeCmsUri);
        $this->logOffRouting($this->request, $this->relativeCmsUri);
        $this->apiRouting($this->relativeCmsUri);
        $this->documentRouting($this->userRights, $this->relativeCmsUri);
        $this->valuelistsRouting($this->userRights, $this->relativeCmsUri);
        $this->sitemapRouting($this->userRights, $this->relativeCmsUri);
        $this->redirectRouting($this->userRights, $this->relativeCmsUri);
        $this->imageRouting($this->userRights, $this->relativeCmsUri);
        $this->filesRouting($this->userRights, $this->relativeCmsUri);
        $this->configurationRouting($this->userRights, $this->relativeCmsUri);
        $this->searchRouting($this->relativeCmsUri);
    }
6616
private function addRoutesForModels()
    {
        foreach ($this->_models as $model) {
            $modelName = strtolower($model);
            $mainUrl = '/' . $modelName;
            $resourceUrl = '/' . $modelName . '/' . '[:id]';
            $controllerName = $model . 'Controller';

            $controller = new $controllerName();

            if ($model::$get_all_enabled) {
                $this->_router->respond('get', $mainUrl, function ($request) use ($controller) {
                    $controller->getAll();
                });
            }

            if ($model::$get_enabled) {
                $this->_router->respond('get', $resourceUrl, function ($request) use ($controller) {
                    $controller->get($request->id);
                });
            }

            if ($model::$create_enabled) {
                $this->_router->respond('post', $mainUrl, function ($request) use ($controller) {
                    $postParams = json_decode(file_get_contents('php://input'));
                    $controller->create($postParams);
                });
            }

            if ($model::$delete_enabled) {
                $this->_router->respond('delete', $resourceUrl, function ($request) use ($controller) {
                    $controller->delete($request->id);
                });
            }

            if ($model::$update_enabled) {
                $this->_router->respond('put', $resourceUrl, function ($request) use ($controller) {
                    $postParams = json_decode(file_get_contents('php://input'));
                    $controller->update($request->id, $postParams);
                });
            }
        }
    }
245598
protected function createMenuFile()
    {
        $file = $this->directory.'/menu.php';

        $contents = $this->getStub('menu');
        $this->laravel['files']->put($file, $contents);
        $this->line('<info>Menu file was created:</info> '.str_replace(base_path(), '', $file));
    }
274026
protected function appendRouteFile()
    {
        $name = $this->qualifyClass($this->getNameInput());
        $nameWithoutNamespace = str_replace($this->getDefaultNamespace(trim($this->rootNamespace(), '\\')).'\\', '', $name);

        $file = $this->option('api') ? base_path('routes/api.php') : base_path('routes/web.php');
        $routeName = $this->getRouteName($name);
        $routePath = $this->getRoutePath($name);

        $routeDefinition = 'Route::get(\''.$routePath.'\', \''.$nameWithoutNamespace.'\')->name(\''.$routeName.'\');'.PHP_EOL;

        if ($this->option('parent') || $this->option('model') || $this->option('resource')) {
            $asExploded = explode('/', $routePath);
            if (count($asExploded) > 1) {
                array_pop($asExploded);
                $as = implode('.', $asExploded);
                if ($this->option('api'))
                    $routeDefinition = 'Route::apiResource(\''.$routePath.'\', \''.$nameWithoutNamespace.'\', [ \'as\' => \''.$as.'\' ]);'.PHP_EOL;
                else $routeDefinition = 'Route::resource(\''.$routePath.'\', \''.$nameWithoutNamespace.'\');'.PHP_EOL;
            } else {
                if ($this->option('api'))
                    $routeDefinition = 'Route::apiResource(\''.$routePath.'\', \''.$nameWithoutNamespace.'\', [ \'as\' => \'api\' ]);'.PHP_EOL;
                else $routeDefinition = 'Route::resource(\''.$routePath.'\', \''.$nameWithoutNamespace.'\');'.PHP_EOL;
            }
        }

        file_put_contents($file, $routeDefinition, FILE_APPEND);

        $this->warn($file.' modified.');
    }
1033978
function createLogDirectory()
    {
        $this->files->ensureDirExists(VALET_HOME_PATH.'/Log', user());

        $this->files->touch(VALET_HOME_PATH.'/Log/nginx-error.log');
    }
1244704
public function create()
	{	
		$blog_dir = getcwd() . '/' . $this->name . '/';
		$this->createBlogDirectory($blog_dir);
		$this->createConfigFile($blog_dir);
		$this->createTemplateFile($blog_dir);
	}
1073764
protected function createDirectories()
    {
        if (! $this->files->isDirectory($directory = app_path('Forms/Auth/Passwords'))) {
            $this->files->makeDirectory($directory, 0755, true);
        }

        if (! $this->files->isDirectory($directory = app_path('Http/Controllers/Auth'))) {
            $this->files->makeDirectory($directory, 0755, true);
        }

        if (! $this->files->isDirectory($directory = resource_path('views/auth/passwords'))) {
            $this->files->makeDirectory($directory, 0755, true);
        }

        if (! $this->files->isDirectory($directory = resource_path('views/settings'))) {
            $this->files->makeDirectory($directory, 0755, true);
        }
    }