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

Split translation strings into multiple strings files #492

Closed
robinpaulson opened this issue Jul 8, 2020 · 6 comments
Closed

Split translation strings into multiple strings files #492

robinpaulson opened this issue Jul 8, 2020 · 6 comments

Comments

@robinpaulson
Copy link
Contributor

As per #364 (comment)

This will make them easier to manage. There are multiple ways we could group them:

  1. according to the groups I've already laid out in Reorder translation strings and add subheadings to strings.xml for all languages #455
  2. according to the activity/fragment which uses them
  3. ???

All suggestions welcome.

@fAntel
Copy link
Contributor

fAntel commented Jul 9, 2020

Both option will face situation when string from one file is used on several screens or in several groups. I like second option and in addition I think a good option would be to put aside non-translatable strings in separate file or files (for example keys for preferences).
My experience says that no matter which option will be used, it's easier to find a string by searching all the files than try to remember where it lays. Therefore, it should be just highlighted which approach is used so that new strings are add with this approach in mind.

@robinpaulson
Copy link
Contributor Author

string from one file is used on several screens or in several groups.

yeah, this thought crossed my mind too

put aside non-translatable strings in separate file or files

yep, good thinking

option 3: put the strings in alphabetical order, maximum 20 (or whatever) to a file

@fAntel
Copy link
Contributor

fAntel commented Jul 13, 2020

I don't see the point in option 3. The goal of splitting string, as I see it, is to protect us from accidental reordering of strings which can complicate the life of translators.

@robinpaulson
Copy link
Contributor Author

@fAntel

Sure, that sounds like good reason not to go for (3), I guess was doing a brain dump more than proper thinking

@robinpaulson
Copy link
Contributor Author

put aside non-translatable strings in separate file

done. now to split the rest of the strings into multiple files

robinpaulson added a commit that referenced this issue Sep 24, 2020
@robinpaulson
Copy link
Contributor Author

I split the strings (English only so far) in way that felt reasonable to me, but it's probably arbitrary. We'll see how it goes before changing the other languages, maybe it wasn't such a good choice I did.

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