config

package
v1.2.6 Latest Latest
Warning

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

Go to latest
Published: Jan 11, 2018 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	DefaultRemote   string       `ini:"default_remote"`
	NoAutocomplete  bool         `ini:"disable_autocomplete_autoinstall"`
	NoColor         bool         `ini:"disable_colors"`
	NotifyUpdates   bool         `ini:"notify_updates"`
	ReleaseChannel  string       `ini:"release_channel"`
	LastUpdateCheck string       `ini:"last_update_check"`
	PastVersion     string       `ini:"past_version"`
	NextVersion     string       `ini:"next_version"`
	EnableAnalytics bool         `ini:"enable_analytics"`
	AnalyticsID     string       `ini:"analytics_id"`
	EnableCURL      bool         `ini:"enable_curl"`
	Path            string       `ini:"-"`
	Remotes         remotes.List `ini:"-"`
	// contains filtered or unexported fields
}

Config of the application

func (*Config) Load

func (c *Config) Load() error

Load the configuration

func (*Config) Save

func (c *Config) Save() error

Save the configuration

type Context

type Context struct {
	// contains filtered or unexported fields
}

Context structure

func NewContext added in v1.1.5

func NewContext(params ContextParams) Context

NewContext with received params and uninitialized configuration

func Setup

func Setup(path string) (wectx Context, err error)

Setup the environment

func (*Context) Config added in v1.1.5

func (c *Context) Config() *Config

Config gets the configuration

func (*Context) Infrastructure added in v1.1.5

func (c *Context) Infrastructure() string

Infrastructure used on the context

func (*Context) InfrastructureDomain added in v1.1.5

func (c *Context) InfrastructureDomain() string

InfrastructureDomain used on the context

func (*Context) Remote added in v1.1.5

func (c *Context) Remote() string

Remote used on the context

func (*Context) ServiceDomain added in v1.1.5

func (c *Context) ServiceDomain() string

ServiceDomain used on the context

func (*Context) SetEndpoint added in v1.1.5

func (c *Context) SetEndpoint(remote string) error

SetEndpoint for the context

func (*Context) Token added in v1.1.5

func (c *Context) Token() string

Token used on the context

func (*Context) Username added in v1.1.5

func (c *Context) Username() string

Username used on the context

type ContextParams added in v1.1.5

type ContextParams struct {
	Remote               string
	Infrastructure       string
	InfrastructureDomain string
	ServiceDomain        string
	Username             string
	Token                string
}

ContextParams is the set of environment configurations

Jump to

Keyboard shortcuts

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