Add initial last.fm client implementation
This commit is contained in:
@@ -41,6 +41,7 @@ type configOptions struct {
|
||||
AuthWindowLength time.Duration
|
||||
|
||||
Scanner scannerOptions
|
||||
LastFM lastfmOptions
|
||||
|
||||
// DevFlags. These are used to enable/disable debugging and incomplete features
|
||||
DevLogSourceLine bool
|
||||
@@ -51,6 +52,12 @@ type scannerOptions struct {
|
||||
Extractor string
|
||||
}
|
||||
|
||||
type lastfmOptions struct {
|
||||
ApiKey string
|
||||
Secret string
|
||||
Language string
|
||||
}
|
||||
|
||||
var Server = &configOptions{}
|
||||
|
||||
func LoadFromFile(confFile string) {
|
||||
@@ -107,6 +114,7 @@ func init() {
|
||||
viper.SetDefault("authwindowlength", 20*time.Second)
|
||||
|
||||
viper.SetDefault("scanner.extractor", "taglib")
|
||||
viper.SetDefault("lastfm.language", "en")
|
||||
|
||||
// DevFlags. These are used to enable/disable debugging and incomplete features
|
||||
viper.SetDefault("devlogsourceline", false)
|
||||
|
||||
Reference in New Issue
Block a user