Mark user interface strings

For now exclude command help, as cobra itself is not localizable yet.
This commit is contained in:
Philipp Wolfer 2023-12-09 16:43:14 +01:00
parent 511b71b909
commit d6ca8d33f7
No known key found for this signature in database
GPG key ID: 8FDF744D4919943B
27 changed files with 1005 additions and 95 deletions

View file

@ -26,6 +26,7 @@ import (
"github.com/spf13/cobra"
"go.uploadedlobster.com/scotty/internal/config"
"go.uploadedlobster.com/scotty/internal/i18n"
)
var serviceListCmd = &cobra.Command{
@ -37,7 +38,7 @@ var serviceListCmd = &cobra.Command{
for _, s := range config.AllServicesAsList() {
fmt.Printf("%v\n", s.Name)
if verbose {
fmt.Printf("\tbackend: %v\n", s.Backend)
fmt.Println(i18n.Tr("\tbackend: %v", s.Backend))
for k, v := range s.ConfigValues {
fmt.Printf("\t%v: %v\n", k, v)
}