Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

plugin language packs #511

Open
liedekef opened this issue Dec 31, 2022 · 5 comments
Open

plugin language packs #511

liedekef opened this issue Dec 31, 2022 · 5 comments

Comments

@liedekef
Copy link
Contributor

Hi,

the code works fine for me, thanks for that. Any hints on how to also automate language updates via github? The regular plugin updatae works fine, so should I just add language assets of some kind to the release?

@YahnisElsts
Copy link
Owner

That feature currently doesn't exist for GitHub/Bitbucket/etc repositories. Right now, the update checker doesn't make any attempt to find language packs among release assets or in the repository itself.

In principle, I wouldn't be against such a feature being added, but I'm not sure if there is an established way to distribute translation updates via GitHub.

@liedekef
Copy link
Contributor Author

liedekef commented Jan 2, 2023

Well, a suggestion for github would be: when working with releases, create an extra asset for the languages that have changed (I'm not sure if WP uses zip files for languages though). The code can then search for it as it does on WP: use the plugin name + installed language codes as filter (of course those then need to be ignored when searching for the release itself). You could even imagine searching for "pluginname.zip" as a default asset (if assets are enabled), making it even esier for users.

@YahnisElsts
Copy link
Owner

For what it's worth, I can confirm that WordPress uses ZIP files for language updates. PUC already supports translation/language pack updates for plugins that use the custom JSON-based metadata format.

@liedekef
Copy link
Contributor Author

liedekef commented Jan 3, 2023

So, that would mean you'd only need to generate that json based on available language files then (if based on the plugin name) :-)

@YahnisElsts
Copy link
Owner

It wouldn't be quite that simple, but essentially yes - generate and/or retrieve that data structure.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants