Skip to content

[translations] Improve maintainer docs and automation #619

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

Merged
merged 4 commits into from
Nov 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/i18n-consistency-checker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
language: [ja, zh]
language: [ja, zh, pt-br, gl]
steps:
- uses: actions/checkout@v3
with:
Expand All @@ -24,7 +24,7 @@ jobs:
id: check-consistency
run: |
# Declare the flags
declare -A flags=( ["ja"]=":jp: Japanese" ["zh"]=":cn: Chinese")
declare -A flags=( ["ja"]=":jp: Japanese" ["zh"]=":cn: Chinese" ["pt-br"]=":brazil: Brazilian Portuguese" ["gl"]="Galician")

issue_title="${flags['${{matrix.language}}']}: Content Consistency Issue"

Expand Down
9 changes: 8 additions & 1 deletion pattern-categorization/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,15 @@ To test your changes locally, you can also generate the mind map yourself like t
We are using `node 12.x` at the moment.

```
# install the markmap CLI
npm install -g markmap-cli
npx markmap --no-toolbar innersource-program-mind-map.md

# then generate the mindmap (it will open in your browser automatically)
npx markmap --no-toolbar innersource-program-mind-map.md -o innersource-program-mind-map.html

# to generate the mindmap for a different language, run the script on the files in the respetive subfolder.
# e.g. for Galician (`gl`)
npx markmap --no-toolbar gl/innersource-program-mind-map.md -o gl/innersource-program-mind-map.html
```

## Future Ideas for Categorization
Expand Down
21 changes: 21 additions & 0 deletions translation/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,13 @@ There are a few things you should prepare before starting a translation project.

However, since git does not create empty folders, it is better to create directories accordingly or add `.keep` files to keep folders.

### Translating Visuals (images, mindmap, etc)

Most of the translations have not translated the text in the visuals (e.g. in images, the mindmap, etc). However if you like, you can!

- To translate the mindmap, create a new folder similar to [pattern-categorization/gl](../pattern-categorization/gl/). Then edit the file `innersource-program-mind-map.md` in there, and run the scripts as explained [here](../pattern-categorization/README.md).
- To add translated visuals, add a subfolder in `assets/img`, see [assets/img/gl/](../assets/img/gl/) as an example. Make sure that in the markdown files of your patterns you link to the correct image files.

### Translation Quality and Review Process

We consider it best practice to have **at least one native speaker** review the translation.
Expand All @@ -62,3 +69,17 @@ They will then get notified on any fixes/additions to the translation in the fut
When you complete a translation under `/translation/<YOUR_LANGUAGE>/`, a GitHub Actions pipeline will run to generate the output for publication in the gitbook. The process is described in detail in [/book/README.md](/book/README.md).

[^1]: Replace `<YOUR_LANGUAGE>` with the [2-letter ISO 639-1 language code](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes) for your language.

## Maintainer Section

This documentation contains information that is only relevant for maintainers of this repo.
If you are just creating a new translation you do not need this information!

**If you are a maintainer of this repo, keep reading :)**

When a new translation is added, there are a couple of tasks to do:

a) determine a translation lead, and add them to the relevant files. See [code change](https://github.com/InnerSourceCommons/InnerSourcePatterns/commit/95b8fc76b64909af5e95bf93fad6e7c105307812)
b) [book.yml](../.github/workflows/book.yml) - update the GitHub Actions that generate book. See [code change](https://github.com/InnerSourceCommons/InnerSourcePatterns/commit/241bdf2a12c8750c66e71865a770d321cca67511)
c) [i18n-consistency-checker.yaml](../.github/workflows/i18n-consistency-checker.yaml) - update the GitHub Actions that does the consistency checks. See [code change](https://github.com/InnerSourceCommons/InnerSourcePatterns/pull/619/commits/fce53091faac83b99de8d699d7672a44810408f0)
d) (optional) [generate-mindmap.yml](../.github/workflows/generate-mindmap.yml) - if the mindmap was translated too, you need to update the GitHub Actions that regenerates the mindmap as well