Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BuildGitProvider ¶
func BuildGitProvider(config Config) (gitprovider.Client, error)
BuildGitProvider builds a gitprovider.Client for the provided Config. It returns an error if the Config.Provider is not supported, or if the construction of the client fails.
Types ¶
type Config ¶
type Config struct {
// Provider defines the GitProvider.
Provider GitProvider
// Hostname is the HTTP/S hostname of the Provider,
// e.g. github.example.com.
Hostname string
// Username contains the username used to authenticate with
// the Provider.
Username string
// Token contains the token used to authenticate with the
// Provider.
Token string
// CABunle contains the CA bundle to use for the client.
CaBundle []byte
}
Config defines the configuration for connecting to a GitProvider.
type GitProvider ¶
type GitProvider string
GitProvider holds a Git provider definition.
const ( GitProviderGitHub GitProvider = "github" GitProviderGitLab GitProvider = "gitlab" GitProviderStash GitProvider = "stash" )
Click to show internal directories.
Click to hide internal directories.