Skip to content

Commit

Permalink
Merge pull request #626 from deltragon/document-validate-po
Browse files Browse the repository at this point in the history
Document validate_po.py script in readme and github PR template
  • Loading branch information
archisman-panigrahi authored Aug 7, 2024
2 parents b811ecf + 3a8e5b0 commit 2b634e8
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
## Description

Describe your changes here, and link to related issues if available.

Reminder to run `python validate_po.py --extract` if you have added new translatable strings.
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,14 @@ For more details, please check the issue: [#329](https://github.com/slgobinath/S

Thirdparty plugins are available at another GitHub repository: [safeeyes-plugins](https://github.com/slgobinath/safeeyes-plugins). More details about how to write your own plugin and how to install third-party plugin are available there.

## Local development

When adding new translatable strings in the source code, make sure to run `python validate_po.py --extract` to add them to the translation template. You will need to install `python3-polib` for this.

Examples for translatable strings are `_("This is a string")` in Python code, or `<property name="label" translatable="yes">This is a label</property>` in Glade/xml files.

To ensure the new strings are well-formed, you can use `python validate_po.py --validate`.

## How to Release?

0. Run `update-po.sh` to generate new translation files (which will be eventually updated by translators). Commit and push the changes to the master branch.
Expand Down

0 comments on commit 2b634e8

Please sign in to comment.