Early Bird Registration for DrupalCon Portland 2024 is open! Register by 23:59 PST on 31 March 2024, to get $100 off your ticket.
Problem/Motivation
When we using composer manager to manage Drupal module packages with composer we does not add explicitly the dependencies of modules into composer.json of application but we should have all packages required by modules on install it.
To assume composer with pathauto we just need to add an composer.json.
Proposed resolution
Add it and inform composer we have token / ctools required.
Comment | File | Size | Author |
---|---|---|---|
#2 | add_composer_json_to-2851062-2.patch | 1.49 KB | woprrr |
Comments
Comment #2
woprrr CreditAttribution: woprrr as a volunteer commentedComment #3
BerdirWe actually removed this on purpose to avoid problems with specific version dependencies and so on that we had before. drupal.org automatically adds this.
Comment #4
woprrr CreditAttribution: woprrr as a volunteer commentedOk @Berdir, but for now we have a small 'sémantic' problem about that when we manage our project with composer. We are forced to add token/ctools into composer.json on global project and that is my problem. What's the problem about specific version dependencies ? can we avoid that with extra {} to make alias ? For now except add dependencies into composer.json on my project `we don't have any solution` ? Sorry to be insistent, I just try to push my thoughts and found a solution.
Thank to your super speed response @berdir you're magic :D
Comment #5
BerdirThis works just fine for me on a fresh drupal-project?
I've done absolutely nothing special.
Comment #6
krina.addweb CreditAttribution: krina.addweb at AddWeb Solution Pvt. Ltd. commented@woprrr ,Thanks for the patch , it works for me also.
Comment #7
woprrr CreditAttribution: woprrr as a volunteer commentedOh ! I have a doubt about how drupal packages brings its information without composer.json to inform it, by packages informations like packagist (that sounds great but it's not our case) drupal.org seems to inform via .info of project but effectively the version granularity are * ... that seem problematic IMHO.
Yes that are done without composer.json I didn't say why previously I have these problem.
Then no need to add these issue now. Sorry for disturb @berdir we have another issue tu decide where D.O add composer.json automatically and where we can indicate to composer what version each version need specificaly ?
@krina.addweb you have an same problem with what case ? (you have updated pathauto and he can't be download your dependencies).
Comment #8
krina.addweb CreditAttribution: krina.addweb at AddWeb Solution Pvt. Ltd. commented@woprrr ,i installed this module with drush command and its working properly.using composer.json it also works for me.
thanks
Comment #9
BerdirI'd talk to @Mixologic. Note that we don't specify version dependencies info.yml, I assume that if we would then it would actually respect that.
I'm setting this to postponed for now, until we have a reason to add a composer.json.
Comment #10
idebr CreditAttribution: idebr at iO commentedTo expand on #3:
This was done in #2766303: Remove composer.json and namespace dependencies
Comment #11
brayfe CreditAttribution: brayfe at Slalom commentedUse of Drush 9 may require this project to add a composer.json file. See referencing issue for context.
Comment #12
xmacinfoPathauto incluses a composer.json file. Let's close this issue.