Skip to content

Conversation

@nvdaes
Copy link

@nvdaes nvdaes commented Dec 20, 2025

No description provided.

@nvdaes
Copy link
Author

nvdaes commented Dec 20, 2025

Description

This PR add the [nvdaL10n repo](https://github.com/nvdaes/nvdaL10n as a submodule.

The addonTemplate branch is added with path _l10n.

Note that an l10n.json file can be created in the main project, since storing it in the submodule folder produced an error.

@seanbudd and others, please feel free to fork the repo or create pull requests if you consider it appropriate.

@seanbudd
Copy link
Member

Is it possible to just integrate a pre-built l10nUtil.exe rather than the full code? Or do we need individual scripts?

@nvdaes
Copy link
Author

nvdaes commented Dec 30, 2025

Sean wrote:

Is it possible to just integrate a pre-built l10nUtil.exe rather than the full code?

I think it's possible, of course preserving required modifications for the template, or you may produce an l10nUtil.exe for both (NVDA and the addon-template).
Please let me know if something is required from me.

@nvdaes
Copy link
Author

nvdaes commented Dec 30, 2025

Also, if this is done, I may not release my translateNvdaAddonsWithCrowdin add-on, in case people prefers to use l10nUtils, since the add-on blocks NVDA when it download translations for specific languages.

@seanbudd
Copy link
Member

I think it would be easiest to just integrate the pre-made exe into NVDA and the template.
I was thinking the l10nUtil should be a repo which produces the l10nUtil.exe, and we just fetch the latest release of that here and in NVDA when it is updated.

@nvdaes
Copy link
Author

nvdaes commented Dec 30, 2025

I like the idea about a repo for l10nUtil. I imagine that you would create it. Let me know if something is required from my side.

@seanbudd
Copy link
Member

I can ask if we can schedule it. Currently we weren't planning on taking on work for the add-on template, but since this will save us in the long-term development of both NVDA and this template I think we might be able to justify it.

@seanbudd
Copy link
Member

While we wait for that, for now, could you design the add-on template changes in #1 using NVDA's l10nUtil.exe? e.g. just get the exe from a random alpha. we can later turn it into a separate repo using your work in https://github.com/nvdaes/nvdaL10n as a base

@nvdaes
Copy link
Author

nvdaes commented Dec 30, 2025

I'm copying files into a dummy NVDA branch locally, i.e., modified l10nUtil.py, markdownTranslate.py etc, and then run scons launcher, to build the executable and test locally with docker and act.

@seanbudd
Copy link
Member

I think if we are incorporating an l10nUtil.exe here, it should be signed by us before this is merged. When the PR is ready and working with the exe, please send us the source code in some form so we can create a signed copy

@nvdaes
Copy link
Author

nvdaes commented Dec 30, 2025

I'm working on this:

  1. I don't know the exact syntax to create an executable with uv and py2exe. I'm asking Copilot to help with this. Perhaps you can provide some feedback here.
  2. l10nUtil in the addonTemplate uses a getFiles function to get/store the ids in Crowdin of addonName.pot and addonName.md. In contrast, in NVDA ids are known and stored in the Python module.
  3. To get the addonName, in the addonTemplate, buildVars.py is used and imported in l10nUtil.py.
  4. In NVDA, choices are used to limit the files used in commands, but this is not the case with add-ons.

I'm thinking about creating a variable named isAddon, False by default, or something like that. We can use my Crowdin project for add-ons, and NV Access Crowdin project for NVDA files.
Also, should we make possible to configure, for example with an argument, other Crowdin projects? I'm not sure since translators may prefer to use just a project, but in the other hand may be people wishing to use their own projects in Crowdin.

Also, when files are updated, not uploaded to Crowdin for the first time, we use crowdinSync in the add-on template.
Should be imported in l10nUtil, or scripts should be run using just crowdinSync? Perhaps you prefer the last option since NVDA uses crowdinSync in GitHub Actions.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants