Skip to content

dev Release 0.1.3

Latest
Compare
Choose a tag to compare
@github-actions github-actions released this 07 Sep 16:10

通过 viper.ReadInConfig() 是否返回 viper.ConfigFileNotFoundError 判断默认配置文件是否存在的方法, 在腾讯云轻量级服务器ubuntu 20.04有问题
(配置文件不存在时没有报配置文件不存在, 而是报 while parsing config: yaml: control characters are not allowed)
改为先判断默认配置文件是否存在, 不存在时初始化, 然后再读取配置