fix(yay): give priority to LC_MESSAGES. fixes #1442

This commit is contained in:
jguer 2021-01-29 22:45:42 +01:00
parent f00630fd0c
commit c221d5ebbd
No known key found for this signature in database
GPG key ID: 6D6CC9BEA8556B35

View file

@ -19,7 +19,11 @@ func initGotext() {
localePath = envLocalePath
}
gotext.Configure(localePath, os.Getenv("LANG"), "yay")
if os.Getenv("LC_MESSAGES") != "" {
gotext.Configure(localePath, os.Getenv("LC_MESSAGES"), "yay")
} else {
gotext.Configure(localePath, os.Getenv("LANG"), "yay")
}
}
func initAlpm(cmdArgs *settings.Arguments, pacmanConfigPath string) (*pacmanconf.Config, bool, error) {