I maintain a module on Drupal.org, the jQuery Colorpicker module, which has a requirement on a 3rd party library. I created a composer.json file in the module root. When I originally installed it, I navigated to the module root and ran composer update
, which created vendor folder in my module directory, and loaded the library to this vendor directory. I then released a beta version of the module.
One user who downloaded the library ran composer drupal-update
from core, which installed the library to the DRUPAL_ROOT/vendor folder. I'm thinking this is the correct way to go.
So I deleted the vendor folder from my module folder, as well as the composer.lock folder from my module folder.
However, when I run composer drupal-update
in my drupal root, it does not install the library to my vendor folder.
I'm not really sure where to go with this - do I need to add something to my module, or is there a required command that needs to be run somewhere for Drupal to install the library when running composer drupal-update
? I haven't worked a lot with composer, so I'm trying to find the proper way to do this so my users can use the module in the standard Drupal way.
composer require drupal/jquery_colorpicker
in root, and I got the error "[InvalidArgumentException] Could not find package drupal/jquery_colorpicker at any version for your minimum-stability (dev)." – Jaypan Jan 15 '17 at 10:07