Skip to content
This repository has been archived by the owner on Jul 14, 2023. It is now read-only.

Migration of non-English translations to v5.5 using messages.xml as the basic structure #29

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
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
18 changes: 18 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Migration of DSpace XMLUI lang
## About
The aim of this project is to migrate all non-English translations to
v5.5

##Quick usage
1. Place `messages.xml`, `lang-util.py`, `file-iterator.py` in the _i18n_
folder.
2. Issue the command `python3 file-iterator.py` to convert all old xml
files to the latest version.

###Notes
- Translation strings from the old translation file are migrated over
by comparing keys.
- If a key in the latest version does not exist in the older version,
it defaults to English
- `messages.xml` is taken from the master 5.5 release of DSpace.

11 changes: 11 additions & 0 deletions file_iterator.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-

import os
for file in os.listdir("."):
if file.endswith(".xml"):
if file is not "messages.xml":
print(file)
os.system('python3 lang-util.py migrate -f ' + file)
os.system('rm ' + file)
os.system('cp output.xml ' + file)
1,103 changes: 250 additions & 853 deletions src/main/webapp/i18n/messages_ar.xml

Large diffs are not rendered by default.

375 changes: 295 additions & 80 deletions src/main/webapp/i18n/messages_bg.xml

Large diffs are not rendered by default.

3,721 changes: 2,480 additions & 1,241 deletions src/main/webapp/i18n/messages_ca.xml

Large diffs are not rendered by default.

4,139 changes: 2,363 additions & 1,776 deletions src/main/webapp/i18n/messages_ca_ES.xml

Large diffs are not rendered by default.

1,418 changes: 567 additions & 851 deletions src/main/webapp/i18n/messages_cs.xml

Large diffs are not rendered by default.

1,538 changes: 760 additions & 778 deletions src/main/webapp/i18n/messages_de.xml

Large diffs are not rendered by default.

1,514 changes: 1,135 additions & 379 deletions src/main/webapp/i18n/messages_el.xml

Large diffs are not rendered by default.

4,172 changes: 1,956 additions & 2,216 deletions src/main/webapp/i18n/messages_es.xml

Large diffs are not rendered by default.

342 changes: 178 additions & 164 deletions src/main/webapp/i18n/messages_et.xml

Large diffs are not rendered by default.

3,911 changes: 2,066 additions & 1,845 deletions src/main/webapp/i18n/messages_eu.xml

Large diffs are not rendered by default.

507 changes: 112 additions & 395 deletions src/main/webapp/i18n/messages_fi.xml

Large diffs are not rendered by default.

2,417 changes: 1,271 additions & 1,146 deletions src/main/webapp/i18n/messages_fr.xml

Large diffs are not rendered by default.

4,468 changes: 2,475 additions & 1,993 deletions src/main/webapp/i18n/messages_gl.xml

Large diffs are not rendered by default.

65 changes: 28 additions & 37 deletions src/main/webapp/i18n/messages_id.xml

Large diffs are not rendered by default.

1,389 changes: 1,065 additions & 324 deletions src/main/webapp/i18n/messages_it.xml

Large diffs are not rendered by default.

1,662 changes: 1,122 additions & 540 deletions src/main/webapp/i18n/messages_ja.xml

Large diffs are not rendered by default.

4,305 changes: 2,133 additions & 2,172 deletions src/main/webapp/i18n/messages_pl.xml

Large diffs are not rendered by default.

714 changes: 331 additions & 383 deletions src/main/webapp/i18n/messages_pt_BR.xml

Large diffs are not rendered by default.

2,830 changes: 1,423 additions & 1,407 deletions src/main/webapp/i18n/messages_ru.xml

Large diffs are not rendered by default.

230 changes: 185 additions & 45 deletions src/main/webapp/i18n/messages_sw.xml

Large diffs are not rendered by default.

344 changes: 243 additions & 101 deletions src/main/webapp/i18n/messages_tr.xml

Large diffs are not rendered by default.

1,129 changes: 821 additions & 308 deletions src/main/webapp/i18n/messages_uk.xml

Large diffs are not rendered by default.