githubapp

package
v0.0.0-...-1d2b55d Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2026 License: MIT Imports: 16 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

This section is empty.

Types

type Config

type Config struct {
	AppId      int64  `yaml:"appId"`
	PrivateKey string `yaml:"privateKey"`
}

type Platform

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

func NewPlatform

func NewPlatform(config Config) (Platform, error)

NewPlatform creates a GitHub platform

func (Platform) AuthMethod

func (n Platform) AuthMethod(repo api.Repository) githttp.AuthMethod

func (Platform) CommitAndPush

func (n Platform) CommitAndPush(repo api.Repository, base string, branch string, message string, dir string) error

func (Platform) CreateMergeRequest

func (n Platform) CreateMergeRequest(repository api.Repository, sourceBranch string, title string, description string) error

func (Platform) CreateOrUpdateMergeRequest

func (n Platform) CreateOrUpdateMergeRequest(repository api.Repository, sourceBranch string, title string, description string, key string) error

func (Platform) CreateTag

func (n Platform) CreateTag(repository api.Repository, tagName string, commitHash string, message string) error

func (Platform) EnvironmentVariables

func (n Platform) EnvironmentVariables(repo api.Repository, environmentName string) ([]api.CIVariable, error)

func (Platform) Environments

func (n Platform) Environments(repo api.Repository) ([]api.CIEnvironment, error)

func (Platform) FileContent

func (n Platform) FileContent(repository api.Repository, branch string, path string) (string, error)

func (Platform) FindRepository

func (n Platform) FindRepository(path string) (api.Repository, error)

FindRepository looks up the installation that covers the repository and fetches it with an installation-scoped client

func (Platform) FindRepositoryById

func (n Platform) FindRepositoryById(id int64) (api.Repository, error)

FindRepositoryById fetches a repository by id. The installation is resolved via the undocumented GET /repositories/{id}/installation endpoint, if that fails with 404 every installation is tried until one has access.

func (Platform) Languages

func (n Platform) Languages(repo api.Repository) (map[string]int, error)

func (Platform) Merge

func (n Platform) Merge(repo api.Repository, mergeRequest api.MergeRequest, mergeStrategy api.MergeStrategyOptions) error

func (Platform) MergeRequest

func (n Platform) MergeRequest(repo api.Repository, number int) (api.MergeRequest, error)

func (Platform) MergeRequestDiff

func (n Platform) MergeRequestDiff(repo api.Repository, mergeRequest api.MergeRequest) (api.MergeRequestDiff, error)

func (Platform) MergeRequests

func (n Platform) MergeRequests(repo api.Repository, options api.MergeRequestSearchOptions) ([]api.MergeRequest, error)

func (Platform) Name

func (n Platform) Name() string

func (Platform) Releases

func (n Platform) Releases(repository api.Repository, limit int) ([]api.Release, error)

func (Platform) Repositories

func (n Platform) Repositories(opts api.RepositoryListOpts) ([]api.Repository, error)

func (Platform) Slug

func (n Platform) Slug() string

func (Platform) SubmitReview

func (n Platform) SubmitReview(repo api.Repository, mergeRequest api.MergeRequest, approved bool, message *string) error

func (Platform) Tags

func (n Platform) Tags(repository api.Repository, limit int) ([]api.Tag, error)

func (Platform) Variables

func (n Platform) Variables(repo api.Repository) ([]api.CIVariable, error)

Jump to

Keyboard shortcuts

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