Home > Backend Development > PHP Tutorial > Mac下安装composer后不能安传composerAsset

Mac下安装composer后不能安传composerAsset

WBOY
Release: 2016-06-06 20:20:02
Original
1162 people have browsed it

先上码如下。

<code>➜  ~  php /usr/local/bin/composer global require "fxp/composer-asset-plugin:~1.1.0"
Changed current directory to /Users/mac/.composer
PHP Fatal error:  Call to undefined method Composer\Package\Version\VersionParser::parseLinks() in /Users/mac/.composer/vendor/fxp/composer-asset-plugin/Repository/VcsPackageFilter.php on line 270

Fatal error: Call to undefined method Composer\Package\Version\VersionParser::parseLinks() in /Users/mac/.composer/vendor/fxp/composer-asset-plugin/Repository/VcsPackageFilter.php on line 270
➜  ~  php /usr/local/bin/composer global require "fxp/composer-asset-plugin:~1.1.4-bata"
Changed current directory to /Users/mac/.composer
PHP Fatal error:  Call to undefined method Composer\Package\Version\VersionParser::parseLinks() in /Users/mac/.composer/vendor/fxp/composer-asset-plugin/Repository/VcsPackageFilter.php on line 270

Fatal error: Call to undefined method Composer\Package\Version\VersionParser::parseLinks() in /Users/mac/.composer/vendor/fxp/composer-asset-plugin/Repository/VcsPackageFilter.php on line 270
</code>
Copy after login
Copy after login

刚开始安装composerAsset 1.0.0版本的时候没问题,后安装1.0.4-bata版本后成功后,我将composer进行了全局安装,但是再执行这个就报上面的错误,搜索了不少资料,但是貌似都没用,删除composer.phar后,重新全局安装,还是没有变化,错误如初,所以只能求指点。

回复内容:

先上码如下。

<code>➜  ~  php /usr/local/bin/composer global require "fxp/composer-asset-plugin:~1.1.0"
Changed current directory to /Users/mac/.composer
PHP Fatal error:  Call to undefined method Composer\Package\Version\VersionParser::parseLinks() in /Users/mac/.composer/vendor/fxp/composer-asset-plugin/Repository/VcsPackageFilter.php on line 270

Fatal error: Call to undefined method Composer\Package\Version\VersionParser::parseLinks() in /Users/mac/.composer/vendor/fxp/composer-asset-plugin/Repository/VcsPackageFilter.php on line 270
➜  ~  php /usr/local/bin/composer global require "fxp/composer-asset-plugin:~1.1.4-bata"
Changed current directory to /Users/mac/.composer
PHP Fatal error:  Call to undefined method Composer\Package\Version\VersionParser::parseLinks() in /Users/mac/.composer/vendor/fxp/composer-asset-plugin/Repository/VcsPackageFilter.php on line 270

Fatal error: Call to undefined method Composer\Package\Version\VersionParser::parseLinks() in /Users/mac/.composer/vendor/fxp/composer-asset-plugin/Repository/VcsPackageFilter.php on line 270
</code>
Copy after login
Copy after login

刚开始安装composerAsset 1.0.0版本的时候没问题,后安装1.0.4-bata版本后成功后,我将composer进行了全局安装,但是再执行这个就报上面的错误,搜索了不少资料,但是貌似都没用,删除composer.phar后,重新全局安装,还是没有变化,错误如初,所以只能求指点。

https://github.com/francoispluchino/composer-asset-plugin/pull/133

  • Linux : rm -rf ~/.composer/vendor/fxp

  • Windows : rm -r%APPDATA%\Composer\vendor\fxp

  • composer global require "fxp/composer-asset-plugin:~1.1.1"

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template