config

package
v1.0.0-alpha.21 Latest Latest
Warning

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

Go to latest
Published: Sep 16, 2022 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DefaultConfig = Config{
	URL: "localhost:8081",
}
View Source
var DefaultName = "tigris-cli"

Functions

func Load

func Load(name string, config interface{})

func Save

func Save(name string, config interface{}) error

Types

type Config

type Config struct {
	ApplicationID     string        `json:"application_id" yaml:"application_id,omitempty" mapstructure:"application_id"`
	ApplicationSecret string        `json:"application_secret" yaml:"application_secret,omitempty" mapstructure:"application_secret"`
	Token             string        `json:"token" yaml:"token,omitempty"`
	URL               string        `json:"url" yaml:"url,omitempty"`
	UseTLS            bool          `json:"use_tls" yaml:"use_tls,omitempty" mapstructure:"use_tls"`
	Timeout           time.Duration `json:"timeout" yaml:"timeout,omitempty"`
	Protocol          string        `json:"protocol" yaml:"protocol,omitempty"`
	Log               Log           `json:"log" yaml:"log,omitempty"`
}

type Log

type Log struct {
	Level string `json:"level" yaml:"level,omitempty"`
}

Jump to

Keyboard shortcuts

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