Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
Global GlobalConfig `mapstructure:"global"`
Template TemplateConfig `mapstructure:"template"`
}
Config 用于表示配置文件的根结构
type GlobalConfig ¶
type GlobalConfig struct {
// 创建模版的类型
Type string `mapstructure:"-"`
// 接口网关地址
APIEndpoint string `mapstructure:"api_endpoint"`
// GIT代码仓库的域名
GitDomain string `mapstructure:"git_domain"`
// 服务所在的产品代号
ProductCode string `mapstructure:"product_code"`
// 服务的名称
ShortName string
// cli的版本
ReleaseVersion string `mapstructure:"release-version"`
}
GlobalConfig 用于表示全局通用配置结构
type TemplateConfig ¶
type TemplateConfig struct {
Service TemplateService `mapstructure:"service"`
}
Templates 用于表示各代码类型的模版配置结构
type TemplateService ¶
type TemplateService struct {
// 服务的接口版本
APIVersion string `mapstructure:"api-version"`
}
TemplateService 用于表示微服务类型模版的配置结构
Click to show internal directories.
Click to hide internal directories.