如果您想重命名您的应用程序文件夹,这只是其中几种方法之一.
php artisan app:name YourNamespace
4)将其粘贴在那里
class Application extends Illuminate\Foundation\Application {
/**
* this is the default for the application path
*/
protected $appBasePath = 'app';
public function __construct($basePath = null)
{
$this->registerBaseBindings();
$this->registerBaseServiceProviders();
$this->registerCoreContainerAliases();
if ($basePath) $this->setBasePath($basePath);
}
public function setAppPath($path) {
// store the path in the class only
$this->appBasePath = $path;
// set the path in the container (using this class's path to reset it)
return app()->__set('path', $this->path());
}
/**
* Get the path …
Run Code Online (Sandbox Code Playgroud)