inpsyde / wp-translation-downloader

Composer plugin to download WordPress translations
MIT License
46 stars 3 forks source link

[Docs] Difference between `composer install` and `composer wp-translation-downloader:download` #36

Closed strarsis closed 1 year ago

strarsis commented 1 year ago

What is the difference between composer install and composer wp-translation-downloader:download? When only composer install is invoked, the core language files are missing, when composer wp-translation-downloader:download is invoked, the core language files are also installed. Is it necessary to always run composer wp-translation-downloader:download, as composer install alone wouldn't suffice (for installing the core language files)?

Chrico commented 1 year ago

Hey ☕

Thanks for your issue. We have in wp-translation-downloader a setting called auto-run - see Configuration,md. When this option is enabled (default), than our Composer plugin is automatically executed on composer install. If it is set to false, than you need to run the Composer script composer wp-translation-downloader:download manually after install/update.

In your case - the missing "core language files": Can you please provide a bit more input like your composer.json and wp-translation-downloader.json and the output (verbose) of composer install, so that we can try to reproduce your problem? :)

strarsis commented 1 year ago

Used composer.json configuration:

    "wp-translation-downloader": {
      "languages": [
          "de_DE",
          "de_DE_formal"
      ],
      "languageRootDir": "web/app/languages"
    }

The auto-run option is omitted, not explicitly set to false, so autorun should be enabled. No wp-translation-downloader.json is used, all the translation download-related configuration is in composer.json.

Chrico commented 1 year ago

Can you please paste your full composer.json (you can clean up if there are any "client"-dependencies). How do your require and require-dev dependencies look like? What other Composer Plugins are you using? 🙃

strarsis commented 1 year ago

I simply forgot to git-ignore the translations lock file - I erroneously assumed that it is treated like the composer lock file. After git ignoring the lock file and removing it, the translation download process works correctly.