Symfony中常用命令


  CSS文件的更新

php app/console assets:install web/

Entity的生成
    根据数据库定义,生产Entity的命令

根据数据库表生成yml文件(或其他xml..)
php app/console doctrine:mapping:convert yml ./src/HRSystem/CommonBundle/Resources/config/doctrine/metadata/orm --from-database --force

根据数据库(yml)生成对应影射类
php app/console doctrine:mapping:import HRSystemCommonBundle annotation
php app/console doctrine:generate:entities HRSystemCommonBundle

创建Bundle命令

php app/console generate:bundle --namespace=MLGP/xxxBundle --format=yml

清除缓存

php app/console cache:clear
原文地址:https://www.cnblogs.com/Kakasi/p/2861032.html