I've cloned civicrm-core (4.7.28) and civicrm-drupal (switched to branch 8.x-4.7.28-rc) into my top level modules dir of my Drupal 8.4. I was able to install dependencies into vendor dir for civicrm-core using composer. I get the following errors when trying to do same for civicrm-drupal:

Loading composer repositories with package information Updating dependencies (including require-dev) Your requirements could not be resolved to an installable set of packages.

Problem 1 - The requested package civicrm/civicrm-core could not be found in any version, there may be a typo in the package name.

Potential causes: - A typo in the package name - The package is not available in a stable-enough version according to your minimum-stability setting see https://getcomposer.org/doc/04-schema.md#minimum-stability for more details. - It's a private package and you forgot to add a custom repository to find it

From what I gather the problem is simply a path issue, as civicrm-core 4.7.28 is in a peer dir. As it seems bad practice to modify the composer.json file to point to local path and I wish to keep core/drupal projects in separate dir, there must be a simple solution which I've been unable to stumble on thus far.

Any suggestions?


1 Answer 1


UPDATE: You can use this method but instead of a version 5.x in the composer command specify dev-master.

You can also use buildkit with e.g. target d8rec-clean. See https://github.com/civicrm/civicrm-drupal-8/pull/37


Here's what I've been doing. I don't think it's the ideal solution and am curious if anyone else has a better way.

  1. Use the roundearth installer as normal to install the latest "numbered" version. (https://gitlab.com/roundearth/drupal-civicrm-project)

  2. Hack the vendor/roundearth/civicrm-composer-plugin/src/Handler.php file so that:

    (a) getCivicrmCoreVersion() returns 'NIGHTLY'

    (b) addMissingCivicrmFiles() uses https://download.civicrm.org/latest/civicrm-NIGHTLY-drupal.tar.gz as the civicrm_archive_url.

  3. Delete vendor/civicrm/civicrm-core

  4. Run composer require civicrm/civicrm-core:dev-master civicrm/civicrm-drupal-8:dev-master

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.