mirror of
https://github.com/go-gitea/gitea
synced 2025-07-19 00:38:36 +00:00
milestone: create page
This commit is contained in:
@@ -134,6 +134,7 @@ var (
|
||||
|
||||
// I18n settings.
|
||||
Langs, Names []string
|
||||
dateLangs map[string]string
|
||||
|
||||
// Other settings.
|
||||
ShowFooterBranding bool
|
||||
@@ -148,6 +149,14 @@ var (
|
||||
HasRobotsTxt bool
|
||||
)
|
||||
|
||||
func DateLang(lang string) string {
|
||||
name, ok := dateLangs[lang]
|
||||
if ok {
|
||||
return name
|
||||
}
|
||||
return "en"
|
||||
}
|
||||
|
||||
func init() {
|
||||
IsWindows = runtime.GOOS == "windows"
|
||||
log.NewLogger(0, "console", `{"level": 0}`)
|
||||
@@ -353,6 +362,7 @@ func NewConfigContext() {
|
||||
|
||||
Langs = Cfg.Section("i18n").Key("LANGS").Strings(",")
|
||||
Names = Cfg.Section("i18n").Key("NAMES").Strings(",")
|
||||
dateLangs = Cfg.Section("i18n.datelang").KeysHash()
|
||||
|
||||
ShowFooterBranding = Cfg.Section("other").Key("SHOW_FOOTER_BRANDING").MustBool()
|
||||
|
||||
|
Reference in New Issue
Block a user