Files
go-omni/cmd/go-omni/scaffold/templates/api-load.go.tmpl

9 lines
380 B
Cheetah

package config
import omniConfig "git.yuntuo.hk/k2safe/go-omni/config"
// Load resolves explicit file references, binds onto Default and validates.
// Ordinary projects only edit Config, Default, Validate and the selected file.
func Load(path string)(Config,error){
loader,err:=NewLoader();if err!=nil{return Config{},err}
return omniConfig.LoadProject(path,Default(),loader)
}