config

package
v1.0.4-0...-8bba0e1 Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2017 License: BSD-3-Clause Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const Vendordir string = "doget_modules"

Vendordir depicts the basename of the directory where downloaded traits are stored

Variables

This section is empty.

Functions

func SearchPath

func SearchPath() []string

SearchPath Returns search path

Types

type Configuration

type Configuration struct {
	Source       string
	Repositories map[string]map[string]string `yaml:"repositories"`
}

Configuration holds the map of all repository informations parsed from all config files

func Default

func Default() *Configuration

Default configuration supports github.com and bitbucket.org

func Empty

func Empty() *Configuration

Empty configuration

func FromFile

func FromFile(filename string) (result *Configuration, err error)

FromFile Reads configuration from a given file

func (*Configuration) Merge

func (c *Configuration) Merge(sources ...string) (*Configuration, error)

Merge Reads configuration from given sources

func (*Configuration) MustMerge

func (c *Configuration) MustMerge(sources ...string) (*Configuration, error)

MustMerge Reads configuration from given sources and yields an error if none exist

Jump to

Keyboard shortcuts

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