开发者

Why does Doctrine 2 create ~Entity.php file?

开发者 https://www.devze.com 2023-02-15 14:24 出处:网络
When I generate my entities I have a file prefixed with ~ like a backup file or something Is开发者_如何学JAVA it a bug or you need to manually remove them?From the official documentation in Symfony2

When I generate my entities I have a file prefixed with ~ like a backup file or something

Is开发者_如何学JAVA it a bug or you need to manually remove them?


From the official documentation in Symfony2 CLI command:

$> php app/console help doctrine:generate:entities

....

By default, the unmodified version of each entity is backed up and saved (e.g. Product.php~). To prevent this task from creating the backup file, pass the --no-backup option:

 php app/console doctrine:generate:entities Blog/Entity --no-backup

So to summarize, you may add --no-backup option to your command.

0

精彩评论

暂无评论...
验证码 换一张
取 消