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: 2 modules, 3 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

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