package main
import (
"log"
"github.com/lonelymous/goco"
)
type ServerConfig struct {
Host string
Port int
CertFile string
KeyFile string
}
func main() {
serverConfig := &ServerConfig{}
// Setup config
err := goco.InitializeConfig(serverConfig)
if err != nil {
log.Fatalln("error while setup config", err)
}
log.Println(serverConfig)
}
A golang package that reads the contents of the config.ini file into a structure
lonelymous/goco
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
A golang package that reads the contents of the config.ini file into a structure
Topics
Resources
Stars
Watchers
Forks
Packages 0
No packages published