jiraApi

package
v0.0.0-...-909e731 Latest Latest
Warning

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

Go to latest
Published: Jan 8, 2021 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddWorklog

func AddWorklog(key string, min uint64, com string, date string, time string) (models.WorklogResp, error)

Worklog method add worklog to issue

func CreateFixVersion

func CreateFixVersion(projectKey string, version string, createDeploymentIssue bool, summary string, description string, issueType string) error

func CreateIssue

func CreateIssue(projectKey string, summary string, description string, issueType string, version *models.Version) (models.Issue, error)

func CreateVersion

func CreateVersion(projectKey string, version string) (createdVersion models.Version, created bool, err error)

CreateVersion creates new version in specified project

func DeleteWorklog

func DeleteWorklog(key string, id string) (status int, error error)

Delete specified worklog (id) from JIRA issue (key)

func DeleteWorklogForUser

func DeleteWorklogForUser(user string, key string) (sumOk int, sumError int, error error)

DeleteWorklogForUser get worklogs form given issue, filter for given user and delete all worklogs

func GetIssue

func GetIssue(issueKey string) (i models.Issue, error error)

GetIssue method returns issue details

func GetIssueWorkflow

func GetIssueWorkflow(issueKey string) (*models.Workflow, error)

GetIssueWorkflow method returns issue details

func GetIssueWorkflowName

func GetIssueWorkflowName(issueKey string) (name string, error error)

GetIssueWorkflow method returns issue details

func GetIssues

func GetIssues(issueKeys []string) []models.Issue

func GetIssuesInVersions

func GetIssuesInVersions(projectKey string, version string, issueTypes string) (issuesInVersionList models.IssueList, error error)

func GetProject

func GetProject(projectKey string) models.Project

GetProject method returns project details

func GetProjects

func GetProjects() []models.Project

GetProjects method list all projects

func GetTransitionByName

func GetTransitionByName(issueKey string, transitionName string) (models.Transition, error)

GetTransitionByName method returns transition details from issue

func GetTransitions

func GetTransitions(issueKey string) []models.Transition

GetTransitions method returns available transitions for issue

func GetVersion

func GetVersion(projectKey string, version string) (models.Version, error)

GetVersion method returns JIRA version details

func GetVersions

func GetVersions(projectKey string) []models.Version

GetVersions method returns JIRA versions of given project

func Initialize

func Initialize(serverUrl string, username string, password string)

Initialize method is used to initialize API client

func ListWorklog

func ListWorklog(key string) (worklogs models.WorklogList, error error)

ListWorklog for specified JIRa issue

func ReleaseVersion

func ReleaseVersion(projectKey string, version string)

ReleaseVersion method changes project status to "released"

func SetFixVersion

func SetFixVersion(issueKey string, version string) error

SetFixVersion method sets fix version of issue. When version is already set it won't be modified

func TestTransitions

func TestTransitions(workflowPath string, issueKey string) error

TestTransitions method run through all transitions to test Workflow definition

func TransitionIssue

func TransitionIssue(workflowPath string, issueKey string, targetStatus string, excludeStatus string) (status int, error error)

TransitionIssue method executes issue transition

Types

type WorkflowTransitionsMap

type WorkflowTransitionsMap struct {
	Workflow map[string]interface{}
}

func BuildWorkflow

func BuildWorkflow(workflow *models.Workflow, sourceStatus string, targetStatus string) *WorkflowTransitionsMap

func ReadWorkflow

func ReadWorkflow(workflowPath string) (WorkflowTransitionsMap, error)

ReadWorkflow method loads Workflow definition from env var, http url or file

func (WorkflowTransitionsMap) GetOrDefault

func (workflow WorkflowTransitionsMap) GetOrDefault(currentStatus string, targetStatus string) (string, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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