mirror of
https://git.sr.ht/~phw/scotty
synced 2025-04-29 21:27:05 +02:00
Basic i18n setup
This commit is contained in:
parent
20f1732858
commit
a41318d822
10 changed files with 700 additions and 9 deletions
164
internal/translations/locales/de/messages.gotext.json
Normal file
164
internal/translations/locales/de/messages.gotext.json
Normal file
|
@ -0,0 +1,164 @@
|
|||
{
|
||||
"language": "de",
|
||||
"messages": [
|
||||
{
|
||||
"id": "Transferring {Entity} from {SourceName} to {TargetName}...",
|
||||
"message": "Transferring {Entity} from {SourceName} to {TargetName}...",
|
||||
"translation": "Übertrage {Entity} von {SourceName} nach {TargetName}...",
|
||||
"placeholders": [
|
||||
{
|
||||
"id": "Entity",
|
||||
"string": "%[1]s",
|
||||
"type": "string",
|
||||
"underlyingType": "string",
|
||||
"argNum": 1,
|
||||
"expr": "c.entity"
|
||||
},
|
||||
{
|
||||
"id": "SourceName",
|
||||
"string": "%[2]s",
|
||||
"type": "string",
|
||||
"underlyingType": "string",
|
||||
"argNum": 2,
|
||||
"expr": "c.sourceName"
|
||||
},
|
||||
{
|
||||
"id": "TargetName",
|
||||
"string": "%[3]s",
|
||||
"type": "string",
|
||||
"underlyingType": "string",
|
||||
"argNum": 3,
|
||||
"expr": "c.targetName"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "From timestamp: {Timestamp} ({Unix})",
|
||||
"message": "From timestamp: {Timestamp} ({Unix})",
|
||||
"translation": "Ab Zeitstempel: {Timestamp} ({Unix})",
|
||||
"placeholders": [
|
||||
{
|
||||
"id": "Timestamp",
|
||||
"string": "%[1]v",
|
||||
"type": "time.Time",
|
||||
"underlyingType": "struct{wall uint64; ext int64; loc *time.Location}",
|
||||
"argNum": 1,
|
||||
"expr": "timestamp"
|
||||
},
|
||||
{
|
||||
"id": "Unix",
|
||||
"string": "%[2]v",
|
||||
"type": "int64",
|
||||
"underlyingType": "int64",
|
||||
"argNum": 2,
|
||||
"expr": "timestamp.Unix()"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "Import failed, last reported timestamp was {LastTimestamp} ({Unix})",
|
||||
"message": "Import failed, last reported timestamp was {LastTimestamp} ({Unix})",
|
||||
"translation": "Import fehlgeschlagen, der letzte Zeitstempel war {LastTimestamp} ({Unix})",
|
||||
"placeholders": [
|
||||
{
|
||||
"id": "LastTimestamp",
|
||||
"string": "%[1]v",
|
||||
"type": "time.Time",
|
||||
"underlyingType": "struct{wall uint64; ext int64; loc *time.Location}",
|
||||
"argNum": 1,
|
||||
"expr": "result.LastTimestamp"
|
||||
},
|
||||
{
|
||||
"id": "Unix",
|
||||
"string": "%[2]v",
|
||||
"type": "int64",
|
||||
"underlyingType": "int64",
|
||||
"argNum": 2,
|
||||
"expr": "result.LastTimestamp.Unix()"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "Imported {ImportCount} of {TotalCount} {Entity} into {TargetName}.",
|
||||
"message": "Imported {ImportCount} of {TotalCount} {Entity} into {TargetName}.",
|
||||
"translation": "{ImportCount} von {TotalCount} {Entity} in {TargetName} importiert.",
|
||||
"placeholders": [
|
||||
{
|
||||
"id": "ImportCount",
|
||||
"string": "%[1]v",
|
||||
"type": "int",
|
||||
"underlyingType": "int",
|
||||
"argNum": 1,
|
||||
"expr": "result.ImportCount"
|
||||
},
|
||||
{
|
||||
"id": "TotalCount",
|
||||
"string": "%[2]v",
|
||||
"type": "int",
|
||||
"underlyingType": "int",
|
||||
"argNum": 2,
|
||||
"expr": "result.TotalCount"
|
||||
},
|
||||
{
|
||||
"id": "Entity",
|
||||
"string": "%[3]s",
|
||||
"type": "string",
|
||||
"underlyingType": "string",
|
||||
"argNum": 3,
|
||||
"expr": "c.entity"
|
||||
},
|
||||
{
|
||||
"id": "TargetName",
|
||||
"string": "%[4]v",
|
||||
"type": "string",
|
||||
"underlyingType": "string",
|
||||
"argNum": 4,
|
||||
"expr": "c.targetName"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "During the import the following errors occurred:",
|
||||
"message": "During the import the following errors occurred:",
|
||||
"translation": "Während des Imports sind folgende Fehler aufgetreten:"
|
||||
},
|
||||
{
|
||||
"id": "Error: {Err}",
|
||||
"message": "Error: {Err}",
|
||||
"translation": "Fehler: {Err}",
|
||||
"placeholders": [
|
||||
{
|
||||
"id": "Err",
|
||||
"string": "%[1]v",
|
||||
"type": "string",
|
||||
"underlyingType": "string",
|
||||
"argNum": 1,
|
||||
"expr": "err"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "Latest timestamp: {LastTimestamp} ({Unix})",
|
||||
"message": "Latest timestamp: {LastTimestamp} ({Unix})",
|
||||
"translation": "Neuester Zeitstempel: {LastTimestamp} ({Unix})",
|
||||
"placeholders": [
|
||||
{
|
||||
"id": "LastTimestamp",
|
||||
"string": "%[1]v",
|
||||
"type": "time.Time",
|
||||
"underlyingType": "struct{wall uint64; ext int64; loc *time.Location}",
|
||||
"argNum": 1,
|
||||
"expr": "result.LastTimestamp"
|
||||
},
|
||||
{
|
||||
"id": "Unix",
|
||||
"string": "%[2]v",
|
||||
"type": "int64",
|
||||
"underlyingType": "int64",
|
||||
"argNum": 2,
|
||||
"expr": "result.LastTimestamp.Unix()"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
164
internal/translations/locales/de/out.gotext.json
Normal file
164
internal/translations/locales/de/out.gotext.json
Normal file
|
@ -0,0 +1,164 @@
|
|||
{
|
||||
"language": "de",
|
||||
"messages": [
|
||||
{
|
||||
"id": "Transferring {Entity} from {SourceName} to {TargetName}...",
|
||||
"message": "Transferring {Entity} from {SourceName} to {TargetName}...",
|
||||
"translation": "Übertrage {Entity} von {SourceName} nach {TargetName}...",
|
||||
"placeholders": [
|
||||
{
|
||||
"id": "Entity",
|
||||
"string": "%[1]s",
|
||||
"type": "string",
|
||||
"underlyingType": "string",
|
||||
"argNum": 1,
|
||||
"expr": "c.entity"
|
||||
},
|
||||
{
|
||||
"id": "SourceName",
|
||||
"string": "%[2]s",
|
||||
"type": "string",
|
||||
"underlyingType": "string",
|
||||
"argNum": 2,
|
||||
"expr": "c.sourceName"
|
||||
},
|
||||
{
|
||||
"id": "TargetName",
|
||||
"string": "%[3]s",
|
||||
"type": "string",
|
||||
"underlyingType": "string",
|
||||
"argNum": 3,
|
||||
"expr": "c.targetName"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "From timestamp: {Timestamp} ({Unix})",
|
||||
"message": "From timestamp: {Timestamp} ({Unix})",
|
||||
"translation": "Ab Zeitstempel: {Timestamp} ({Unix})",
|
||||
"placeholders": [
|
||||
{
|
||||
"id": "Timestamp",
|
||||
"string": "%[1]v",
|
||||
"type": "time.Time",
|
||||
"underlyingType": "struct{wall uint64; ext int64; loc *time.Location}",
|
||||
"argNum": 1,
|
||||
"expr": "timestamp"
|
||||
},
|
||||
{
|
||||
"id": "Unix",
|
||||
"string": "%[2]v",
|
||||
"type": "int64",
|
||||
"underlyingType": "int64",
|
||||
"argNum": 2,
|
||||
"expr": "timestamp.Unix()"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "Import failed, last reported timestamp was {LastTimestamp} ({Unix})",
|
||||
"message": "Import failed, last reported timestamp was {LastTimestamp} ({Unix})",
|
||||
"translation": "Import fehlgeschlagen, der letzte Zeitstempel war {LastTimestamp} ({Unix})",
|
||||
"placeholders": [
|
||||
{
|
||||
"id": "LastTimestamp",
|
||||
"string": "%[1]v",
|
||||
"type": "time.Time",
|
||||
"underlyingType": "struct{wall uint64; ext int64; loc *time.Location}",
|
||||
"argNum": 1,
|
||||
"expr": "result.LastTimestamp"
|
||||
},
|
||||
{
|
||||
"id": "Unix",
|
||||
"string": "%[2]v",
|
||||
"type": "int64",
|
||||
"underlyingType": "int64",
|
||||
"argNum": 2,
|
||||
"expr": "result.LastTimestamp.Unix()"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "Imported {ImportCount} of {TotalCount} {Entity} into {TargetName}.",
|
||||
"message": "Imported {ImportCount} of {TotalCount} {Entity} into {TargetName}.",
|
||||
"translation": "{ImportCount} von {TotalCount} {Entity} in {TargetName} importiert.",
|
||||
"placeholders": [
|
||||
{
|
||||
"id": "ImportCount",
|
||||
"string": "%[1]v",
|
||||
"type": "int",
|
||||
"underlyingType": "int",
|
||||
"argNum": 1,
|
||||
"expr": "result.ImportCount"
|
||||
},
|
||||
{
|
||||
"id": "TotalCount",
|
||||
"string": "%[2]v",
|
||||
"type": "int",
|
||||
"underlyingType": "int",
|
||||
"argNum": 2,
|
||||
"expr": "result.TotalCount"
|
||||
},
|
||||
{
|
||||
"id": "Entity",
|
||||
"string": "%[3]s",
|
||||
"type": "string",
|
||||
"underlyingType": "string",
|
||||
"argNum": 3,
|
||||
"expr": "c.entity"
|
||||
},
|
||||
{
|
||||
"id": "TargetName",
|
||||
"string": "%[4]v",
|
||||
"type": "string",
|
||||
"underlyingType": "string",
|
||||
"argNum": 4,
|
||||
"expr": "c.targetName"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "During the import the following errors occurred:",
|
||||
"message": "During the import the following errors occurred:",
|
||||
"translation": "Während des Imports sind folgende Fehler aufgetreten:"
|
||||
},
|
||||
{
|
||||
"id": "Error: {Err}",
|
||||
"message": "Error: {Err}",
|
||||
"translation": "Fehler: {Err}",
|
||||
"placeholders": [
|
||||
{
|
||||
"id": "Err",
|
||||
"string": "%[1]v",
|
||||
"type": "string",
|
||||
"underlyingType": "string",
|
||||
"argNum": 1,
|
||||
"expr": "err"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "Latest timestamp: {LastTimestamp} ({Unix})",
|
||||
"message": "Latest timestamp: {LastTimestamp} ({Unix})",
|
||||
"translation": "Neuester Zeitstempel: {LastTimestamp} ({Unix})",
|
||||
"placeholders": [
|
||||
{
|
||||
"id": "LastTimestamp",
|
||||
"string": "%[1]v",
|
||||
"type": "time.Time",
|
||||
"underlyingType": "struct{wall uint64; ext int64; loc *time.Location}",
|
||||
"argNum": 1,
|
||||
"expr": "result.LastTimestamp"
|
||||
},
|
||||
{
|
||||
"id": "Unix",
|
||||
"string": "%[2]v",
|
||||
"type": "int64",
|
||||
"underlyingType": "int64",
|
||||
"argNum": 2,
|
||||
"expr": "result.LastTimestamp.Unix()"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
178
internal/translations/locales/en/out.gotext.json
Normal file
178
internal/translations/locales/en/out.gotext.json
Normal file
|
@ -0,0 +1,178 @@
|
|||
{
|
||||
"language": "en",
|
||||
"messages": [
|
||||
{
|
||||
"id": "Transferring {Entity} from {SourceName} to {TargetName}...",
|
||||
"message": "Transferring {Entity} from {SourceName} to {TargetName}...",
|
||||
"translation": "Transferring {Entity} from {SourceName} to {TargetName}...",
|
||||
"translatorComment": "Copied from source.",
|
||||
"placeholders": [
|
||||
{
|
||||
"id": "Entity",
|
||||
"string": "%[1]s",
|
||||
"type": "string",
|
||||
"underlyingType": "string",
|
||||
"argNum": 1,
|
||||
"expr": "c.entity"
|
||||
},
|
||||
{
|
||||
"id": "SourceName",
|
||||
"string": "%[2]s",
|
||||
"type": "string",
|
||||
"underlyingType": "string",
|
||||
"argNum": 2,
|
||||
"expr": "c.sourceName"
|
||||
},
|
||||
{
|
||||
"id": "TargetName",
|
||||
"string": "%[3]s",
|
||||
"type": "string",
|
||||
"underlyingType": "string",
|
||||
"argNum": 3,
|
||||
"expr": "c.targetName"
|
||||
}
|
||||
],
|
||||
"fuzzy": true
|
||||
},
|
||||
{
|
||||
"id": "From timestamp: {Timestamp} ({Unix})",
|
||||
"message": "From timestamp: {Timestamp} ({Unix})",
|
||||
"translation": "From timestamp: {Timestamp} ({Unix})",
|
||||
"translatorComment": "Copied from source.",
|
||||
"placeholders": [
|
||||
{
|
||||
"id": "Timestamp",
|
||||
"string": "%[1]v",
|
||||
"type": "time.Time",
|
||||
"underlyingType": "struct{wall uint64; ext int64; loc *time.Location}",
|
||||
"argNum": 1,
|
||||
"expr": "timestamp"
|
||||
},
|
||||
{
|
||||
"id": "Unix",
|
||||
"string": "%[2]v",
|
||||
"type": "int64",
|
||||
"underlyingType": "int64",
|
||||
"argNum": 2,
|
||||
"expr": "timestamp.Unix()"
|
||||
}
|
||||
],
|
||||
"fuzzy": true
|
||||
},
|
||||
{
|
||||
"id": "Import failed, last reported timestamp was {LastTimestamp} ({Unix})",
|
||||
"message": "Import failed, last reported timestamp was {LastTimestamp} ({Unix})",
|
||||
"translation": "Import failed, last reported timestamp was {LastTimestamp} ({Unix})",
|
||||
"translatorComment": "Copied from source.",
|
||||
"placeholders": [
|
||||
{
|
||||
"id": "LastTimestamp",
|
||||
"string": "%[1]v",
|
||||
"type": "time.Time",
|
||||
"underlyingType": "struct{wall uint64; ext int64; loc *time.Location}",
|
||||
"argNum": 1,
|
||||
"expr": "result.LastTimestamp"
|
||||
},
|
||||
{
|
||||
"id": "Unix",
|
||||
"string": "%[2]v",
|
||||
"type": "int64",
|
||||
"underlyingType": "int64",
|
||||
"argNum": 2,
|
||||
"expr": "result.LastTimestamp.Unix()"
|
||||
}
|
||||
],
|
||||
"fuzzy": true
|
||||
},
|
||||
{
|
||||
"id": "Imported {ImportCount} of {TotalCount} {Entity} into {TargetName}.",
|
||||
"message": "Imported {ImportCount} of {TotalCount} {Entity} into {TargetName}.",
|
||||
"translation": "Imported {ImportCount} of {TotalCount} {Entity} into {TargetName}.",
|
||||
"translatorComment": "Copied from source.",
|
||||
"placeholders": [
|
||||
{
|
||||
"id": "ImportCount",
|
||||
"string": "%[1]v",
|
||||
"type": "int",
|
||||
"underlyingType": "int",
|
||||
"argNum": 1,
|
||||
"expr": "result.ImportCount"
|
||||
},
|
||||
{
|
||||
"id": "TotalCount",
|
||||
"string": "%[2]v",
|
||||
"type": "int",
|
||||
"underlyingType": "int",
|
||||
"argNum": 2,
|
||||
"expr": "result.TotalCount"
|
||||
},
|
||||
{
|
||||
"id": "Entity",
|
||||
"string": "%[3]s",
|
||||
"type": "string",
|
||||
"underlyingType": "string",
|
||||
"argNum": 3,
|
||||
"expr": "c.entity"
|
||||
},
|
||||
{
|
||||
"id": "TargetName",
|
||||
"string": "%[4]v",
|
||||
"type": "string",
|
||||
"underlyingType": "string",
|
||||
"argNum": 4,
|
||||
"expr": "c.targetName"
|
||||
}
|
||||
],
|
||||
"fuzzy": true
|
||||
},
|
||||
{
|
||||
"id": "During the import the following errors occurred:",
|
||||
"message": "During the import the following errors occurred:",
|
||||
"translation": "During the import the following errors occurred:",
|
||||
"translatorComment": "Copied from source.",
|
||||
"fuzzy": true
|
||||
},
|
||||
{
|
||||
"id": "Error: {Err}",
|
||||
"message": "Error: {Err}",
|
||||
"translation": "Error: {Err}",
|
||||
"translatorComment": "Copied from source.",
|
||||
"placeholders": [
|
||||
{
|
||||
"id": "Err",
|
||||
"string": "%[1]v",
|
||||
"type": "string",
|
||||
"underlyingType": "string",
|
||||
"argNum": 1,
|
||||
"expr": "err"
|
||||
}
|
||||
],
|
||||
"fuzzy": true
|
||||
},
|
||||
{
|
||||
"id": "Latest timestamp: {LastTimestamp} ({Unix})",
|
||||
"message": "Latest timestamp: {LastTimestamp} ({Unix})",
|
||||
"translation": "Latest timestamp: {LastTimestamp} ({Unix})",
|
||||
"translatorComment": "Copied from source.",
|
||||
"placeholders": [
|
||||
{
|
||||
"id": "LastTimestamp",
|
||||
"string": "%[1]v",
|
||||
"type": "time.Time",
|
||||
"underlyingType": "struct{wall uint64; ext int64; loc *time.Location}",
|
||||
"argNum": 1,
|
||||
"expr": "result.LastTimestamp"
|
||||
},
|
||||
{
|
||||
"id": "Unix",
|
||||
"string": "%[2]v",
|
||||
"type": "int64",
|
||||
"underlyingType": "int64",
|
||||
"argNum": 2,
|
||||
"expr": "result.LastTimestamp.Unix()"
|
||||
}
|
||||
],
|
||||
"fuzzy": true
|
||||
}
|
||||
]
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue