I\'ve set up two projects, an \'init\' and a library, which is required by the init. They both have PSR-0 autoloads set, but the autoload values from the library are not add
Try composer dump-autoload
command.
It depends how you installing your library via Composer. For example, when downloading it as package
type (same I believe with composer
type), Composer never reads the composer.json
file, so instead you should use vcs
or git
type. See: GH-6846.
Here is composer.json
which should work:
{
"require": {
"lxp/library": "dev-master"
},
"repositories": [
{
"type": "vcs",
"url": "http://satis.repo.redacted/"
}
]
}
Then run: composer install
.
For troubleshooting, try running:
composer dump-autoload -o -vvv
.composer diagnose -vvv
I see two possible mistakes you may have done that would cause this: