qtranslate / qtranslate-xt

qTranslate-XT (eXTended) - reviving qTranslate-X multilingual plugin for WordPress. A new community-driven plugin soon. Built-in modules for WooCommerce, ACF, slugs and others.
GNU General Public License v2.0
556 stars 105 forks source link

Allow composer/installers v2 #1169

Closed ukasiu closed 2 years ago

ukasiu commented 2 years ago

Hi,

I'm having trouble to use this plugin with trellis, as it requires composer/installer 2.1 and it is conflicting with this plugin dependencies.

herrvigg commented 2 years ago

Sorry, no idea what trellis is about. The support for installer is limited already with WordPress. Can you explain better what you expect? Feel free to send a pull request.

ukasiu commented 2 years ago

When a composer project e.g. based on https://github.com/roots/bedrock requires

"composer/installers": "^2.1"

and I want to add qtranslate-xt it is not possible, because it requires

"composer/installers": "~1.0"

and there is a dependency conflict. I can't see a good reason for qtranslate-xt not to require

"composer/installers": ">1.0"
herrvigg commented 2 years ago

I don't see any problem changing the requirement. The composer.json came from #659 by @TimidRobot who may comment on this.

If I understand well ~1.0 means >=1.0 AND <2.0 which is putting a constraint on newer versions. For a clearer requirement shouldn't it rather be this?

"composer/installers": ">=2.0"

With >1.0 you'd still allow 1.1, no?

herrvigg commented 2 years ago

In reality we don't have any constraint on 2.0 for QTX. We could simply have >=1.0 to remove the constraint on 2.0+.

herrvigg commented 2 years ago

If berock requires

"composer/installers": "^2.1"

and QTX requires

"composer/installers": ">=1.0"

It expect it to install 2.1+ .

herrvigg commented 2 years ago

I've changed the PR #1170 with >=1.0 (to relax all constraints). Let me know if this works.

ukasiu commented 2 years ago

@herrvigg yep, >=1.0 makes more sense