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

Make Emails translatable via transifex #6025

Closed
kobergj opened this issue Apr 6, 2023 · 4 comments · Fixed by #6038
Closed

Make Emails translatable via transifex #6025

kobergj opened this issue Apr 6, 2023 · 4 comments · Fixed by #6038
Assignees

Comments

@kobergj
Copy link
Collaborator

kobergj commented Apr 6, 2023

Email templates are currently stored in https://github.com/owncloud/ocis/tree/master/services/notifications/pkg/email/templates

  1. Remove RenderTemplate code. Hardcode subjects and body as constants into a templates.go file.

  2. Use Template function to mark subjects and body as translatable strings

  3. Add translation steps to notifications service Makefile

  4. Not part of the ticket: Actually translate emails. We first need a way to determine the users preferred language.

cc @dragonchaser @mmattel

@micbar
Copy link
Contributor

micbar commented Apr 7, 2023

I found a new extractor which can also extract variables from template files:

https://github.com/vorlif/xspreak#xspreak

@micbar
Copy link
Contributor

micbar commented Apr 8, 2023

@kobergj @2403905 This is a good project for Roman 👍

@kobergj
Copy link
Collaborator Author

kobergj commented Apr 11, 2023

The new extractor is better than the one we use now. But we probably need a custom solution anyways because of #5924

@2403905 2403905 self-assigned this Apr 11, 2023
2403905 added a commit to 2403905/ocis that referenced this issue Apr 12, 2023
@2403905
Copy link
Contributor

2403905 commented Apr 12, 2023

@micbar @kobergj
Please suggest:

  1. Should I add a new environment variable instead the NOTIFICATIONS_EMAIL_TEMPLATE_PATH?
  2. Which one locale should be used until we determine the users preferred language?https://github.com/owncloud/ocis/pull/6038/files#diff-4849177b19f87c6711bf3fb8b7a84991cf06d64c8c8c05ff5e017c9cc26faa22R90

2403905 added a commit to 2403905/ocis that referenced this issue Apr 14, 2023
The transifex translation add in to the email templates.
The optional environment variable NOTIFICATIONS_TRANSLATION_PATH added to config.
2403905 added a commit to 2403905/ocis that referenced this issue Apr 16, 2023
The transifex translation add in to the email templates.
The optional environment variable NOTIFICATIONS_TRANSLATION_PATH added to config.
2403905 added a commit to 2403905/ocis that referenced this issue Apr 16, 2023
The transifex translation add in to the email templates.
The optional environment variable NOTIFICATIONS_TRANSLATION_PATH added to config.
kobergj added a commit that referenced this issue Apr 18, 2023
Make Emails translatable via transifex #6025
ownclouders pushed a commit that referenced this issue Apr 18, 2023
Make Emails translatable via transifex #6025
@micbar micbar mentioned this issue May 3, 2023
89 tasks
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 a pull request may close this issue.

3 participants