labeldata

package
v2.2.0 Latest Latest
Warning

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

Go to latest
Published: Jun 12, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package labeldata contains shared GitLab label conversion helpers.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewGroupListOptions

func NewGroupListOptions(page, perPage int, search string, withCounts, includeAncestorGroups, includeDescendantGroups, onlyGroupLabels bool) *gl.ListGroupLabelsOptions

NewGroupListOptions builds GitLab options for listing group labels.

func NewProjectListOptions

func NewProjectListOptions(page, perPage int, search string, withCounts, includeAncestorGroups bool) *gl.ListLabelsOptions

NewProjectListOptions builds GitLab options for listing project labels.

func ToMarkdown

func ToMarkdown(label Output) toolutil.LabelMarkdown

ToMarkdown converts shared label output to the toolutil markdown model.

Types

type Output

type Output struct {
	toolutil.HintableOutput
	ID                     int64  `json:"id"`
	Name                   string `json:"name"`
	Color                  string `json:"color"`
	TextColor              string `json:"text_color"`
	Description            string `json:"description"`
	OpenIssuesCount        int64  `json:"open_issues_count"`
	ClosedIssuesCount      int64  `json:"closed_issues_count"`
	OpenMergeRequestsCount int64  `json:"open_merge_requests_count"`
	Priority               int64  `json:"priority"`
	PrioritySpecified      bool   `json:"-"`
	IsProjectLabel         bool   `json:"is_project_label"`
	Subscribed             bool   `json:"subscribed"`
	Archived               bool   `json:"archived"`
}

Output represents a GitLab label shared by project and group label tools.

func GroupOutput

func GroupOutput(label *gl.GroupLabel) Output

GroupOutput converts a GitLab group label to shared output fields.

func ProjectOutput

func ProjectOutput(label *gl.Label) Output

ProjectOutput converts a GitLab project label to shared output fields.

Jump to

Keyboard shortcuts

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