-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/alternative include #13
base: main
Are you sure you want to change the base?
Conversation
Have you tried this with contrib modules installed? It seems to me that an unpatched core index.php will make DrupalKernel think $app_root is within the core git clone, and so contrib modules won't get picked up. |
Hmm, you are right, i forgot some things. :) |
Yup, so basically, (and I should add something like this to the README and maybe the relevant core issues too) we have:
If the Drupal package is symlinked in, then nothing in that package is capable of knowing where the app root is. That information is only known to scaffolded files (because that's where they are) and Composer (because it has the scaffold location defined in composer.json). |
I was investigating a little more and something we also do in our projects is change the autoload.php in the directory above core to point at the other vendor directory outside the core directory from the git repository. This kinda means you still need a change in the core files. Also, in my setup in this branch, drush gets confused in where to find its plugins. It detects the drupal-root perfectly as /repos/drupal/ but when goes to find plugins it still gets confused, i suspect because of the symlinked vendor directory. Anyways, i'm starting to think i might not be able to do this without patched core files indeed. Perhaps the excersise i'm doing is wasted effort :) |
Thanks for investigating anyway, it's always interesting to have new ideas and approaches! I'd like to get core fixed so we don't need to patch it -- there's a link to the issue in the README. Also, if you have any light you can shed on #10 that would be super! |
An experiement if it is possible without patches but with a little trick in the web directory we use on our projects.
This adds:
It seems to work pretty fine but because i use a custom packages.json it is not completely as it would be when in the main repository.
Tested usinig:
drupal-core-development-packages.json
Command:
composer create-project --repository=./drupal-core-development-packages.json joachim-n/drupal-core-development-project coredev5 -vvv