composer-monorepo-plugin icon indicating copy to clipboard operation
composer-monorepo-plugin copied to clipboard

the doc about the way to reference third-party packages in monorepo.json is wrong

Open stof opened this issue 9 years ago • 3 comments
trafficstars

It says that you should use the path relative to the root of the repo, but this is wrong. the actual expectation is to use 'vendor/'.$composerPackageName: https://github.com/beberlei/composer-monorepo-plugin/blob/373f20df3ee82b0633b2961fd035fda6fc3db352/src/main/Monorepo/Build.php#L193 While this matches the composer default installation path, there might be many reasons to have a different path:

  • using a different name for the vendor dir
  • using the target-path property in the package
  • using a custom installer generating a different path

stof avatar May 30 '16 15:05 stof

Btw, the MonorepoInstaller class actually expects the name to be the installation path for all packages, which means that the plugin is probably incompatible with use cases mentioned above.

stof avatar May 30 '16 15:05 stof

Isn't vendor/symfony/symfony relative to the root of the repo? That at least what i mean here.

Currently only working with the default vendor/ is supported.

beberlei avatar Jun 01 '16 17:06 beberlei

@beberlei half of the code expects the installation path, and half of the code expects 'vendor/'.$composerPackageName (which might be the same, but might be totally different). In the case of symfony, it is indeed the same, because it does not match any of the conditions I listed above.

stof avatar Jun 02 '16 08:06 stof