Add support for updating language packs for all installed languges in wp-fix-languages
At the moment wp-fix-languages only installs language packs for the current active site language (set in General Settings). It does not install language packs for plugins and themes for all installed core languages.
When running multilingual sites (with or without Polylang) users have the ability to change their admin language. Plugins that have front end functionality also require language packs for multilingual support.
For instance, when running a site in Finnish (default) and Swedish via Polylang, wp-fix-languages currently only installs core, theme and plugin language packs for Finnish.
You can use wp eval 'array_keys(wp_get_installed_translations("core")["default"]);' to get an array of all installed language locales.
This should also produce the list:
$ wp language core list --status=installed
+----------+--------------+-------------+-----------+--------+---------------------+
| language | english_name | native_name | status | update | updated |
+----------+--------------+-------------+-----------+--------+---------------------+
| fi | Finnish | Suomi | installed | none | 2020-05-24 09:39:32 |
| sv_SE | Swedish | Svenska | installed | none | 2020-05-22 22:23:36 |
+----------+--------------+-------------+-----------+--------+---------------------+
https://github.com/wp-cli/wp-cli/pull/1382/commits/f4922c3b5de1c84d8aa36295c651efe2ae24aca0
Our wp-fix-language already runs
wp language core update
wp language theme update --all
wp language plugin update --all
..which should cover the request you had. Apparently there are cases where it does not work.
Please send me by email info about that site it was so I can look deeper. Thanks!
We have not been able to reproduce this issue, nor did we get futher information about it. We could look at this again when deprecating the wp-languages thing and when we anyway re-review the language pack installations of WordPress and plugins in #76