provider

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Nov 24, 2026 License: Apache-2.0 Imports: 3 Imported by: 0 modules, 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

Overview

Package provider holds the types shared by the service layer and the git bridge for shipping changes to a git host.

Index

Constants

This section is empty.

Variables

View Source
var ErrNoPullRequests = errors.New("this provider has no pull requests")

ErrNoPullRequests means the provider cannot open pull requests (plain git).

View Source
var ErrNotFound = errors.New("no such pull request on the host")

ErrNotFound means the host has no such pull request.

Functions

This section is empty.

Types

type Commit

type Commit struct {
	Tree        hash.Hash
	Message     string
	AuthorName  string
	AuthorEmail string
	When        time.Time
}

Commit is one commit to write: a vx tree and its metadata.

type OpenedPR

type OpenedPR struct {
	Number  int
	URL     string
	Updated bool // an open PR for the branch existed and was updated
}

OpenedPR is the provider's answer.

type PRInfo added in v0.4.0

type PRInfo struct {
	Number int
	URL    string
	State  PRState
	Head   string // source branch
	Base   string // target branch
}

PRInfo is a pull request as the host reports it.

type PRState added in v0.4.0

type PRState string

PRState is where a pull request (a GitLab merge request) stands.

const (
	PRStateOpen   PRState = "open"
	PRStateMerged PRState = "merged"
	PRStateClosed PRState = "closed" // closed or declined without merging
)

type PullRequest

type PullRequest struct {
	Head  string // branch with the changes, e.g. "vx/rate-limiting"
	Base  string // target branch
	Title string
	Body  string
	Draft bool
}

PullRequest is what vx asks the provider to open.

Jump to

Keyboard shortcuts

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