mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-05-31 06:04:35 -04:00
milestone: create page
This commit is contained in:
parent
ce4dcf1e83
commit
3e4cdccf6b
76 changed files with 2883 additions and 3484 deletions
|
@ -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()
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue