I have a foo/foo-lib library that requires defines a specific commit from GitHub:
{ "name": "foo/foo-lib", "repositories": [ { "type": "vcs", "url": "https://github.com/KnpLabs/Gaufrette.git" } ], "require": { "knplabs/gaufrette": "dev-master#2633721877cae79ad461f3ca06f3f77fb4fce02e" } }
and it works fine:
$ composer update Loading composer repositories with package information Updating dependencies (including require-dev) - Updating knplabs/gaufrette dev-master (2633721 => 2633721) Checking out 2633721877cae79ad461f3ca06f3f77fb4fce02e Generating autoload files
but when I need this library in another project:
{ "name": "bar/bar-app", "repositories": [ { "type": "vcs", "url": "ssh://git.example.com/foo-lib" } ], "require-dev": { "foo/foo-lib": "dev-master" } }
it gives a dependency error:
Your requirements could not be resolved to an installable set of packages. Problem 1 - Installation request for foo/foo-lib dev-master -> satisfiable by foo/foo-lib[dev-master]. - foo/foo-lib dev-master requires knplabs/gaufrette dev-master
So, my question is: how to correctly require specific commit from GitHub in my library to be available in dependent packages?
github php composer-php
Maciej Sz Jan 23 '14 at 16:48 2014-01-23 16:48
source share