config

package
v0.1.0-alpha Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2014 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Usage

func Usage()

Usage is like running the builder with -h/--help - it simply prints the usage message to stderr.

Types

type Options

type Options struct {
	// Inform and Exit
	Version     bool `short:"v" description:"Print version and exit"`
	VersionFull bool `long:"version" description:"Print long version and exit"`
	Branch      bool `long:"branch" description:"Print branch and exit"`
	Rev         bool `long:"rev" description:"Print revision and exit"`

	// Runtime Options
	Quiet bool `short:"q" long:"quiet" description:"Produce no output, only exit codes" default:"false"`

	// Features
	Lintfile    string `short:"l" long:"lint" description:"Lint the provided file. Compatible with -q/--quiet"`
	Builderfile string `short:"b" long:"build" description:"The configuration file for Builder"`
}

Options are our command line options, set using the https://github.com/jessevdk/go-flags library.

type Runtime

type Runtime struct {
	builderlogger.Logger
	Options
}

Runtime is a struct of convenience, used for keeping track of our conf options (i.e. passed on the command line or specified otherwise) as well as other useful, global-ish things.

func NewRuntime

func NewRuntime() *Runtime

NewRuntime returns a new Runtime struct instance that contains all of the global-ish things specific to this invokation of builder.

Jump to

Keyboard shortcuts

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