![Forrest logo](/images/logo.png)
laravel:tldr:b6f0a
laravel: Overwrite if the directory already exists.
$ laravel new ${name} --force
try on your machine
This command is used in Laravel, a PHP framework, to create a new Laravel application with a specified name.
Here's a breakdown of the command:
laravel new
: This is the command used to create a new Laravel application.${name}
: This is a placeholder for the application name. You need to replace${name}
with the actual name you want to give to your application. For example, if you want to name your application "example", you would replace${name}
withexample
. The resulting command would belaravel new example
.--force
: This is an optional flag that can be included with the command. When--force
is used, it will automatically install the Laravel application, even if the directory specified for the application name already exists. This flag is useful when you want to overwrite an existing directory and start fresh with a new Laravel application.
To summarize, the command laravel new ${name} --force
is used to create a new Laravel application with a specified name, and the --force
flag is used to overwrite an existing directory if necessary.
This explanation was created by an AI. In most cases those are correct. But please always be careful and
never run a command you are not sure if it is safe.