jit

package
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2015 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ConfigFilename = "config.json"
)

Variables

This section is empty.

Functions

func ConfigPath

func ConfigPath() string

func ExtractIssue

func ExtractIssue(data string) (match string, ok bool)

func FindUsername

func FindUsername(fullName string) (username string)

func IssueURL

func IssueURL(key string) string

func NewAuthenticatedGithubClient

func NewAuthenticatedGithubClient() *github.Client

func NewGithubClient

func NewGithubClient() *github.Client

func NormalizeIssueKey

func NormalizeIssueKey(key string) string

func SaveConfig

func SaveConfig()

func WriteConfig

func WriteConfig(c *Config)

Types

type Config

type Config struct {
	Jira             *JiraConfig       `json:"jira"`
	Github           *GithubConfig     `json:"github"`
	MaxBranchLength  int               `json:"maxBranchLength"`
	AssociatedPaths  []string          `json:"associatedPaths"`
	UserMap          map[string]string `json:"userMap"`
	SignPullRequests bool              `json:"signPullRequests"`
}
var (
	AppConfig *Config
)

func GetConfig

func GetConfig() (config *Config)

type GithubConfig

type GithubConfig struct {
	Username string `json:"username"`
	Token    string `json:"token"`
}

func (*GithubConfig) FilledOut

func (c *GithubConfig) FilledOut() bool

type Issue

type Issue struct {
	*gojira.Issue
}

func GetIssue

func GetIssue(key string, allFields bool) (issue *Issue, err error)

func (*Issue) BranchName

func (i *Issue) BranchName() string

func (*Issue) String

func (i *Issue) String() string

func (*Issue) URL

func (i *Issue) URL() string

type JiraConfig

type JiraConfig struct {
	Host           string `json:"host"`
	ApiPath        string `json:"api_path"`
	ActivityPath   string `json:"activity_path"`
	Login          string `json:"login"`
	Password       string `json:"password"`
	DefaultProject string `json:"defaultProject"`
}

func (*JiraConfig) FilledOut

func (c *JiraConfig) FilledOut() bool

Jump to

Keyboard shortcuts

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