core

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Jul 8, 2025 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

Package core provides the core functionality for interacting with GitLab API.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type App

type App struct {
	// contains filtered or unexported fields
}

App represents the application structure for interacting with GitLab API.

func NewApp

func NewApp(gitlabToken, gitlabURI string) (*App, error)

NewApp creates a new application instance with GitLab client.

func (*App) GetIssues

func (a *App) GetIssues(opts ...GetIssuesOption) ([]*gitlab.Issue, error)

GetIssues retrieves GitLab issues based on the provided options.

type GetIssues

type GetIssues struct {
	ProjectID             int
	GroupID               int
	State                 string
	FilterCreatedAtAfter  time.Time
	FilterCreatedAtBefore time.Time
	FilterUpdatedAtAfter  time.Time
	FilterUpdatedAtBefore time.Time
}

GetIssues contains parameters for retrieving issues from GitLab.

type GetIssuesOption

type GetIssuesOption func(*GetIssues)

GetIssuesOption is a functional option for configuring the GetIssues struct.

func WithClosedIssues

func WithClosedIssues() GetIssuesOption

WithClosedIssues filters issues to only show closed issues.

func WithFilterCreatedAt

func WithFilterCreatedAt(filterCreatedAtAfter time.Time, filterCreatedAtBefore time.Time) GetIssuesOption

WithFilterCreatedAt filters issues by creation date range.

func WithFilterCreatedAtAfter

func WithFilterCreatedAtAfter(filterCreatedAtAfter time.Time) GetIssuesOption

WithFilterCreatedAtAfter filters issues created after the specified time.

func WithFilterCreatedAtBefore

func WithFilterCreatedAtBefore(filterCreatedAtBefore time.Time) GetIssuesOption

WithFilterCreatedAtBefore filters issues created before the specified time.

func WithFilterUpdatedAt

func WithFilterUpdatedAt(filterUpdatedAtAfter time.Time, filterUpdatedAtBefore time.Time) GetIssuesOption

WithFilterUpdatedAt filters issues by update date range.

func WithFilterUpdatedAtAfter

func WithFilterUpdatedAtAfter(filterUpdatedAtAfter time.Time) GetIssuesOption

WithFilterUpdatedAtAfter filters issues updated after the specified time.

func WithFilterUpdatedAtBefore

func WithFilterUpdatedAtBefore(filterUpdatedAtBefore time.Time) GetIssuesOption

WithFilterUpdatedAtBefore filters issues updated before the specified time.

func WithGroupID

func WithGroupID(groupID int) GetIssuesOption

WithGroupID sets the group ID for retrieving issues.

func WithOpenedIssues

func WithOpenedIssues() GetIssuesOption

WithOpenedIssues filters issues to only show opened issues.

func WithProjectID

func WithProjectID(projectID int) GetIssuesOption

WithProjectID sets the project ID for retrieving issues.

func WithState

func WithState(state string) GetIssuesOption

WithState sets the state filter for issues.

Jump to

Keyboard shortcuts

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