PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Saturday, January 22, 2022

[FIXED] Installing Yii composer asset plugin on composer

 January 22, 2022     composer-php, php, yii, yii-components, yii2     No comments   

Issue

I am trying to install "fxp/composer-asset-plugin:^1.2.0" on windows 32bit composer but always failed. Here is the message

Installation failed, reverting ./composer.json to its original content.

[Composer\Downloader\TransportException]
Content-Length mismatch

require [--dev] [--prefer-source] [--prefer-dist] [--no-progress] [--no-suggest] [--no-update] [--no-scripts] [--update-no-dev] [--update-with-dependencies] [--ignore-platform-reqs] [--prefer-stable] [--prefer-lowest] [--sort-packages] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--apcu-autoloader] [--] []...

Anyone know what is the problem here? Please help Thank you


Solution

You should update composer at first with

composer selfupdate

And be sure, you installing "fxp/composer-asset-plugin" globally, like official install guide says:

composer global require "fxp/composer-asset-plugin:^1.2.0"

If you are using windows, try running composer from cmd "as Administator". To clarify, if you have access to global directory, run

composer global show -s

And check output directory manually



Answered By - wormi4ok
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © PHPFixing