Documentation
¶
Index ¶
Constants ¶
View Source
const (
ConfigFileName = "conf/app.json"
)
Variables ¶
This section is empty.
Functions ¶
func ReadConfig ¶
Types ¶
type Config ¶
type Config struct {
Debug bool // 开启 Debug
Addr string // 监听地址 默认为 ${defaultAddr}
DBKey string // 数据库密码 默认随机${defaultKeyLen}位字符
Resource string // 资源文件夹(相对路径) 为空表示使用内置资源 (可包含 lang static, views 文件夹)
Lang string // 默认语言 为空表示使用系统语言
ViewPattern string // 模板文件名正则 为空表示 \.html$ (当有 views 文件夹时)
// contains filtered or unexported fields
}
var AppConf *Config
func (*Config) StaticPath ¶
Click to show internal directories.
Click to hide internal directories.