github

package
v1.0.3 Latest Latest
Warning

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

Go to latest
Published: Oct 26, 2026 License: Apache-2.0 Imports: 8 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ValidatePRReference

func ValidatePRReference(ref string) (owner, repo string, prNumber int, err error)

ValidatePRReference validates and parses a GitHub PR reference Accepts formats: owner/repo#123, https://github.com/owner/repo/pull/123

Types

type Client

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

Client represents a GitHub API client

func NewClient

func NewClient(config Config) *Client

NewClient creates a new GitHub client

func (*Client) PostPRComment

func (c *Client) PostPRComment(owner, repo string, prNumber int, comment string, config Config, dryRun bool) error

PostPRComment posts a comment to a GitHub PR with retry logic

type Config

type Config struct {
	Token          string
	MaxRetries     int
	RetryDelay     time.Duration
	BackoffFactor  float64
	RequestTimeout time.Duration
}

Config holds configuration for GitHub client

Jump to

Keyboard shortcuts

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