Symfony3命令无法打开输入文件:symfony

时间:2016-12-01 12:55:50

标签: php console symfony

环境:XAMPP服务器(windows),PHP 5.6.28(cli),作曲家版本1.2.2 2016-11-03 17:43:15 我有Symfony3命令的问题。我在下面输入了项目目录和输入命令,我可以看到结果:

# php symfony -v
Could not open input file: symfony

下面有要求:

# php bin\symfony_requirements

Symfony Requirements Checker
~~~~~~~~~~~~~~~~~~~~~~~~~~~~

> PHP is using the following php.ini file:
  D:\xampp\php\php.ini

> Checking Symfony requirements:
  .............................WWW......


 [OK]
 Your system is ready to run Symfony projects


Optional recommendations to improve your setup
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

 * intl extension should be available
   > Install and enable the intl extension (used for validators).

 * a PHP accelerator should be installed
   > Install and/or enable a PHP accelerator (highly recommended).

 * realpath_cache_size should be at least 5M in php.ini
   > Setting "realpath_cache_size" to e.g. "5242880" or "5M" in
   > php.ini* may improve performance on Windows significantly in some
   > cases.


Note  The command console could use a different php.ini file
~~~~  than the one used with your web server. To be on the
      safe side, please check the requirements from your web
      server using the web/config.php script.

项目由命令生成:

composer create-project symfony/framework-standard-edition my_project_name

由于上述问题,我无法使用php symfony new project_name。 此topis的解决方案对我来说也不起作用:

http://stackoverflow.com/questions/16855008/could-not-find-input-file-symfony

使用app / console的结果:

Could not open input file: app/console

1 个答案:

答案 0 :(得分:2)

'console'文件被移动到Symfony3中的'bin'目录 http://symfony.com/doc/current/console/usage.html

无论如何,这里描述了使用Symfony Installer的最新方法https://github.com/symfony/symfony-installer