Error running php composer.phar search
天蓬老师
天蓬老师 2017-05-24 11:34:07
0
3
562

I downloaded and installed composer on the server, and then moved composer.phar to /usr/local/bin/composer
Then I opened the project directory and ran php composer.phar search. Could not open input file appeared : composer.phar,
I also tried other commands, but still got this error.

天蓬老师
天蓬老师

欢迎选择我的课程,让我们一起见证您的进步~~

reply all(3)
滿天的星座

The file name after renaming is composer, not composer.phar. Enter it directlycomposer search

刘奇

composer search xxx

漂亮男人

composer.phar 是一个打包了的 php 程序。其实还是一个文件,和其它的 php 文件一样可以 php composer.phar 打开,同样也可以 ./composer.phar。但是你把 composer.phar 移动到 /usr/local/bin 去了,而且改了名字 composer,所以你可以直接使用 composer 命令了。至于为什么用 php composer.phar 不行了,因为你的文件在当前目录没有 composer.phar Yeah.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template