vcs

package module
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Dec 7, 2025 License: LGPL-3.0 Imports: 2 Imported by: 0

README

vcs

Latest Version License Github Workflow Status Codecov

Go libraries for interacting with Version Control Systems (vcs). Primarily oriented around resolving versions, interacting with Git, and downloading releases.

Supported VCS

  • Github
  • Gitlab

License

LGPL-3.0

Documentation

Overview

Package vcs contains constants for the VCS providers supported by the libraries provided.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Override

type Override struct {
	// URLBase is the base URL that this override should apply to.
	URLBase string

	// Provider is the provider to override to.
	Provider Provider
}

Override represents an override for a given URL passed to ProviderFromURL.

type Provider

type Provider string

Provider represents a VCS provider.

const (
	// ProviderGithub represents Github.
	ProviderGithub Provider = "github"

	// ProviderGitlab represents Gitlab.
	ProviderGitlab Provider = "gitlab"
)

Contains constants for provider enum values.

func ProviderFromURL

func ProviderFromURL(url string, overrides []Override) (Provider, error)

ProviderFromURL returns the VCS provider from a URL.

Directories

Path Synopsis
examples
download-release command
Package main implements an example download of a release.
Package main implements an example download of a release.
Package git contains functions for interacting with Git repositories using the Git CLI.
Package git contains functions for interacting with Git repositories using the Git CLI.
internal
execerr
Package execerr contains an error handler for errors returned by the exec library.
Package execerr contains an error handler for errors returned by the exec library.
fileinfo
Package fileinfo provides a simple implementation of os.FileInfo for remote files.
Package fileinfo provides a simple implementation of os.FileInfo for remote files.
Package releases implements functions for interacting with 'Releases' provided by VCS providers.
Package releases implements functions for interacting with 'Releases' provided by VCS providers.
github
Package github implements opts.Fetcher for Github releases.
Package github implements opts.Fetcher for Github releases.
gitlab
Package gitlab implements opts.Fetcher for Gitlab releases.
Package gitlab implements opts.Fetcher for Gitlab releases.
internal/opts
Package opts contains the options and interfaces for the releases package.
Package opts contains the options and interfaces for the releases package.
Package resolver implements a way to resolve versions of software based on the provided criteria.
Package resolver implements a way to resolve versions of software based on the provided criteria.
Package token contains functions for getting an authenticated token from a user's machine for a given VCS provider.
Package token contains functions for getting an authenticated token from a user's machine for a given VCS provider.
internal/github
Package github implements shared.Provider for Github.
Package github implements shared.Provider for Github.
internal/gitlab
Package gitlab contains Gitlab specific [token.Provider]s.
Package gitlab contains Gitlab specific [token.Provider]s.
internal/shared
Package shared contains shared provider implementations.
Package shared contains shared provider implementations.

Jump to

Keyboard shortcuts

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