config

package
v0.0.0-...-373ed42 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 25, 2020 License: MIT Imports: 2 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Repos map[string]string

Repos as read from the config file, a map of GitHub repositories full names (e.g. ccrama/Slide) to Discord channel IDs.

Functions

func Load

func Load() error

Load the config file located at config.json into the variables exposed by this package.

Types

type APITokens

type APITokens struct {
	LastFM  string `json:"last.fm"`
	Discord string `json:"discord"`
}

APITokens used to authenticate the bot with various services.

var Tokens *APITokens

Tokens is the set of APITokens read from the config file.

type Config

type Config struct {
	Tokens *APITokens        `json:"tokens"`
	Repos  map[string]string `json:"Repos"`
}

Config is the top level structure of the config.json file.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL