Supported Languages for Marty Media Server
- Go 100%
|
All checks were successful
Build and Release / Checks (push) Successful in 30s
Build and Release / Code Coverage (push) Successful in 43s
Build and Release / Code Coverage-1 (push) Successful in 43s
Build and Release / Build (push) Successful in 24s
Build and Release / Build-1 (push) Successful in 34s
Build and Release / Semantic Release (push) Successful in 21s
|
||
|---|---|---|
| .forgejo/workflows | ||
| .gitignore | ||
| .releaserc | ||
| go.mod | ||
| iso639.go | ||
| iso639.json | ||
| iso639_test.go | ||
| LICENSE.txt | ||
| README.md | ||
golanguage
A Go library providing lookup maps for ISO 639 language codes used in the Marty Media Server.
Features
- ISO 639-2 lookup — by both
iso639-2T(terminologic) andiso639-2B(bibliographic) codes - ISO 639-3 lookup — by 3-letter identifier
- Zero runtime I/O — data is embedded via
//go:embed, no external files needed - Package-level maps — lookups are available as package variables, parsed once at init
Installation
go get git.martin-riedl.de/marty-media/golanguage
Example
package main
import (
"fmt"
language "git.martin-riedl.de/marty-media/golanguage"
)
func main() {
// Lookup by ISO 639-3 code
if lang, ok := language.ISO639_3["deu"]; ok {
fmt.Printf("Name: %s\n", lang.Name) // German
fmt.Printf("ISO 639-1: %s\n", lang.ISO639_1) // de
fmt.Printf("Local name: %s\n", lang.LocalizedName) // Deutsch
}
// Lookup by ISO 639-2B code
if lang, ok := language.ISO639_2["fre"]; ok {
fmt.Printf("Name: %s\n", lang.Name) // French
fmt.Printf("ISO 639-1: %s\n", lang.ISO639_1) // fr
}
}
License
Copyright 2026 Martin Riedl. Licensed under the Apache License, Version 2.0.