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

Mod translation updater: S"Hello"-type calls aren't picked up #14494

Open
rollerozxa opened this issue Mar 26, 2024 · 1 comment · May be fixed by #14574
Open

Mod translation updater: S"Hello"-type calls aren't picked up #14494

rollerozxa opened this issue Mar 26, 2024 · 1 comment · May be fixed by #14574
Labels
Feature request Issues that request the addition or enhancement of a feature @ Startup / Config / Util Supported by core dev Not on the roadmap, yet some core dev decided to take care of this PR

Comments

@rollerozxa
Copy link
Member

rollerozxa commented Mar 26, 2024

Summary

Say you have some code like this:

minetest.chat_send_all(S"Hello")

Omitting the brackets when there is only a single string argument is valid in Lua and is used in mods like i3, but the translation updater doesn't pick up on this.

Steps to reproduce

Run the script on the above code put in a lua file and try to generate locale with the tool.

@rollerozxa rollerozxa added the Unconfirmed bug Bug report that has not been confirmed to exist/be reproducible label Mar 26, 2024
@appgurueu appgurueu added Feature request Issues that request the addition or enhancement of a feature Supported by core dev Not on the roadmap, yet some core dev decided to take care of this PR and removed Unconfirmed bug Bug report that has not been confirmed to exist/be reproducible labels Mar 26, 2024
@appgurueu
Copy link
Contributor

appgurueu commented Mar 26, 2024

Labeling this as a feature request because strictly speaking the script is "correct" in that it should handle the forms it claims to pick up correctly. Supporting another form (aside with S'...' for consistency? and perhaps S[[...]], possibly with equals signs) is a sensible feature request which I support however - I personally like to use this syntactic sugar.

This should also be easy enough to implement by adapting the regex.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature request Issues that request the addition or enhancement of a feature @ Startup / Config / Util Supported by core dev Not on the roadmap, yet some core dev decided to take care of this PR
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants