config

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2017 License: MIT Imports: 3 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 {
	Harvest        HarvestConfig        `json:"harvest"`
	PivotalTracker PivotalTrackerConfig `json:"pivotal_tracker"`
}

Config is a struct that contains configuration information

func DefaultConfig

func DefaultConfig() (config Config, e error)

DefaultConfig returns the defualt config from ".get-to-work"

func FromFile

func FromFile(path string) (cfg Config, e error)

FromFile returns a Config given a file path.

func (*Config) Save

func (config *Config) Save(path string) (err error)

Save persists the current state of the config struct to a fileContents

func (*Config) SaveDefaultConfig

func (config *Config) SaveDefaultConfig() (err error)

type HarvestConfig

type HarvestConfig struct {
	AccountID      string `json:"account_id"`
	ProjectID      string `json:"project_id"`
	TaskID         string `json:"task_id"`
	LatTimeEntryID int    `json:"last_time_entry_id,omitempty"`
}

HarvestConfig is a struct that saves Harvest configuration information

type PivotalTrackerConfig

type PivotalTrackerConfig struct {
	ProjectID   string `json:"project_id"`
	LastStoryID int    `json:"last_story_id,omitempty"`
}

PivotalTrackerConfig is a struct that saves PT confituration information

Jump to

Keyboard shortcuts

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