silverstripe / vendor-plugin

Allows Silverstripe vendor modules to expose directories to the webroot
BSD 3-Clause "New" or "Revised" License
5 stars 16 forks source link

Better support for adding non-composer folder #7

Open sminnee opened 7 years ago

sminnee commented 7 years ago

Context

When you first create a module and it's not on packagist yet, you'll most likely add it to a project without composer require. (Forcing the use of composer's repositories section would be awful, and at the very start of dev it might not even be available in a remote repo)

For most SilverStripe behaviour this is okay — the manifest-based autoloader can be used in place of composer's PSR-4 one, and SilverStripe will find the module folder either in the root, or in vendor/.

However, if you've put your module into vendor then the resources will need to be copied out .

Proposed solutions

Either of the following would work:

Firesphere commented 7 years ago

I would prefer the latter. A composer update should fix it imo, adding more overhead of another composer command sounds tedious.

dhensby commented 6 years ago

I don't see this as being an issue that warrants our effort. If someone is using a module in the way described it should be added to their repositories section of composer.json so they don't rely on packagist.

Whilst coping missing assets would be nice, I don't think that this context is so important.