dmitryd / dd_deepl

3 stars 9 forks source link

Supporting non-composer mode - at least a bit #19

Open BluechipZellAmSee opened 6 months ago

BluechipZellAmSee commented 6 months ago

I know you already stated to not support non-composer mode. Nevertheless I would like to ask you if you could make the following changes to your code:

Composer mode: In DeeplTranslationService.php there is a check for composer mode on line 95. Maybe you could change this code to

if (Environment::isComposerMode() || class_exists(Translator::class)) {

Or maybe add a configuration option via ext_conf_template.txt like "I know what I'm doing, ignore composer mode restriction".

General In ext_emconf.php change the PHP dependency constraint to 8.1.0-8.3.99 to align with composer.json

Background The background to my request is that we still have projects in non-composer mode where we would like to use your extension. We can provide the necessary 3rd party libraries on our own but without the change in DeeplTranslationService.php we cannot use it without maintaining our own fork.

But of course I understand if you don't want to make those changes 😉

dmitryd commented 6 months ago

None planned... Usually it is easy to rebuild projects to use composer and it adds a lot of benefits. Adding legacy code is not what I would like to add to any new extension. But I will keep the ticket open for now.