script: Add weblatedl.go for downloading updated translations (#8723)

Based on the transifexdl.go script.  Map Weblate language codes to the
existing ones during import.  Do not delete incomplete languages from
repo.
This commit is contained in:
André Colomb
2023-01-08 15:25:00 +01:00
committed by GitHub
parent 458d6cff2a
commit 39c0bfa05a
2 changed files with 182 additions and 0 deletions

View File

@@ -320,6 +320,9 @@ func runCommand(cmd string, target target) {
case "transifex":
transifex()
case "weblate":
weblate()
case "tar":
buildTar(target, tags)
@@ -953,6 +956,11 @@ func transifex() {
runPrint(goCmd, "run", "../../../../script/transifexdl.go")
}
func weblate() {
os.Chdir("gui/default/assets/lang")
runPrint(goCmd, "run", "../../../../script/weblatedl.go")
}
func ldflags(tags []string) string {
b := new(strings.Builder)
b.WriteString("-w")