dst67283 2014-05-23 14:03
浏览 157
已采纳

在Symfony中生成Bundle

Can't find a solution for this on stack.

I'm using ubuntu server,

$php app/console generate:bundle --namespace=WMDN/FirstBundle --format=yml

goes fine until :

Generating the bundle code: OK
Checking that the bundle is autoloaded: FAILED
Confirm automatic update of your Kernel [yes]? yes
Enabling the bundle inside the Kernel: OK
Confirm automatic update of the Routing [yes]? yes
Importing the bundle routing resource: OK


 The command was not able to configure everything automatically.
You must do the following changes manually.


- Edit the composer.json file and register the bundle
namespace in the "autoload" section:

I thought it was permissions, and set the whole dir to 775 and made sure owner was good. I thought it was outdated bug for symfony and deleted whole dir, and got 2.4.4

I'm following a tutorial and their bundle generates just fine and I'd like mine to do it as well.

Why can it not autoload? My Namespace should be good to use. I cannot figure it out. I have composer installed.

Following this tutorial series : http://www.youtube.com/watch?v=GIcY5YYfZ14 and I'd really like to get my first bundle created so I may continue.

In conclusion, what are the reasons a bundle would fail autoload?

  • 写回答

1条回答 默认 最新

  • dqq48152418 2014-05-23 16:38
    关注

    Per to comments, solution was to set the --src parameter correctly.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥60 QQOP数据,什么是op数据号,怎么提取op数据!能不能大量提取(语言-c语言)
  • ¥15 matlab代码 关于微分方程和嵌套的分段函数。
  • ¥15 把VMware项目复制到另一台电脑
  • ¥15 onlyoffice编辑完后立即下载,下载的不是最新编辑的文档
  • ¥15 求caverdock使用教程
  • ¥15 Coze智能助手搭建过程中的问题请教
  • ¥15 12864只亮屏 不显示汉字
  • ¥20 三极管1000倍放大电路
  • ¥15 vscode报错如何解决
  • ¥15 前端vue CryptoJS Aes CBC加密后端java解密