koding / multiconfig

Load configuration from multiple sources in Go
http://godoc.org/github.com/koding/multiconfig
MIT License
454 stars 64 forks source link

Not able to specify configuration file on command line #76

Open sivann opened 6 years ago

sivann commented 6 years ago

Unless I'm missing something obvious, I can't find a way to specify configuration file on command line like app -conf config.toml

Using the flags package on top of multiconfig breaks the helpfile and produces a "flag provided but not defined".

markx commented 5 years ago

This library creates flags according to your config struct. It seems that your config struct doesn't have a conf field, hence the error "flag provided but not defined".