Reputation: 19
I am newbie to Zend and php
While trying to install zf2 i am facing the issue while composer.phar is installed
I have cloned the following repository git clone git://github.com/zendframework/ZendSkeletonApplication.git zf2-tutorial
Then moved into xampp\htdocss
php composer.phar self-update --> This is working and when I run the next command i get an exception.
$ php composer.phar install
Loading composer repositories with package information
Installing dependencies (including require-dev)
- Installing zendframework/zendframework (2.2.1)
Downloading: 100%
[UnexpectedValueException]
'C:\xampp\htdocs\zf2-tutorial\vendor/zendframework/zendframework/30d4a3b0d6 7fcce22fce0aeedb6f1573.1' is not a zip archive.
Upvotes: 0
Views: 3163
Reputation: 26283
I usually use following steps to install Zend Framework 2 with Doctrine or ZF2 without doctrine. Following commands are tested successfully on *nix platform.
To install ZF2 Without doctrine ORM run following commands in your working directory
git clone git://github.com/zendframework/ZendSkeletonApplication.git
php composer.phar self-update
php composer.phar require zendframework/zend-developer-tools:dev-master
cp vendor/zendframework/zend-developer-tools/config/zenddevelopertools.local.php.dist config/autoload/zdt.local.php
chmod 777 data/cache/
//enable modules in config/application.config.php file
return array(
'modules' => array(
'ZendDeveloperTools',
'Application',
),
// [...]
);
git clone git://github.com/zendframework/ZendSkeletonApplication.git
php composer.phar self-update
php composer.phar require doctrine/doctrine-orm-module:0.7.*
php composer.phar require zendframework/zend-developer-tools:dev-master
cp vendor/zendframework/zend-developer-tools/config/zenddevelopertools.local.php.dist config/autoload/zdt.local.php
chmod 777 data/cache/
//enable modules in config/application.config.php file
return array(
'modules' => array(
'ZendDeveloperTools',
'DoctrineModule',
'DoctrineORMModule',
'Application',
),
// [...]
);
Command Line
./vendor/bin/doctrine-module orm:validate-schema
./vendor/bin/doctrine-module orm:schema-tool:create
Upvotes: 1
Reputation: 7243
On a short note, this is a problem that i fell into, basically you need to do, php composer.phar install and then composer.phar update and then composer.phar self update. What i found out was that when you do php composer.phar self-update you do not need to do php composer.phar install as self update command will install and update(both). Try running a program.
Upvotes: 1
Reputation: 5095
It looks like your composer cache contains corrupted items. You should clear your composer cache and try again. The cache directory is called .composer/cache and is located in your composer home directory. Just clear it and re-try.
Upvotes: 0