Uniformly format translation files
This commit is contained in:
parent
d0f0f3ecc4
commit
d5904b1714
28 changed files with 1209 additions and 1211 deletions
|
@ -486,5 +486,4 @@
|
||||||
},
|
},
|
||||||
"tooLong": "Deze tekst is te lang. De tekst heeft {count} lettertekens, er mogen maximaal 255 letters zijn"
|
"tooLong": "Deze tekst is te lang. De tekst heeft {count} lettertekens, er mogen maximaal 255 letters zijn"
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
|
@ -469,7 +469,7 @@ function mergeLayerTranslations() {
|
||||||
const layerFiles = ScriptUtils.getLayerFiles();
|
const layerFiles = ScriptUtils.getLayerFiles();
|
||||||
for (const layerFile of layerFiles) {
|
for (const layerFile of layerFiles) {
|
||||||
mergeLayerTranslation(layerFile.parsed, layerFile.path, loadTranslationFilesFrom("layers"))
|
mergeLayerTranslation(layerFile.parsed, layerFile.path, loadTranslationFilesFrom("layers"))
|
||||||
writeFileSync(layerFile.path, JSON.stringify(layerFile.parsed, null, " "))
|
writeFileSync(layerFile.path, JSON.stringify(layerFile.parsed, null, " ")) // layers use 2 spaces
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -484,7 +484,7 @@ function mergeThemeTranslations() {
|
||||||
|
|
||||||
const allTranslations = new TranslationPart();
|
const allTranslations = new TranslationPart();
|
||||||
allTranslations.recursiveAdd(config, themeFile.path)
|
allTranslations.recursiveAdd(config, themeFile.path)
|
||||||
writeFileSync(themeFile.path, JSON.stringify(config, null, " "))
|
writeFileSync(themeFile.path, JSON.stringify(config, null, " ")) // Themefiles use 2 spaces
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -516,12 +516,11 @@ if (!themeOverwritesWeblate) {
|
||||||
compileTranslationsFromWeblate();
|
compileTranslationsFromWeblate();
|
||||||
}
|
}
|
||||||
genTranslations()
|
genTranslations()
|
||||||
formatFile("./langs/themes/nl.json")
|
const allTranslationFiles = ScriptUtils.readDirRecSync("langs").filter(path => path.endsWith(".json"))
|
||||||
/*const allTranslationFiles = ScriptUtils.readDirRecSync("langs").filter(path => path.endsWith(".json"))
|
|
||||||
for (const path of allTranslationFiles) {
|
for (const path of allTranslationFiles) {
|
||||||
console.log("Formatting ", path)
|
console.log("Formatting ", path)
|
||||||
formatFile(path)
|
formatFile(path)
|
||||||
}*/
|
}
|
||||||
|
|
||||||
|
|
||||||
// SOme validation
|
// SOme validation
|
||||||
|
|
Loading…
Reference in a new issue