gitlab

package
v4.0.0-...-1bf0545 Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2024 License: MIT Imports: 10 Imported by: 0

README

gitlab

gitlab://user:personal-access-token@gitlab_url/project_id/path#ref

URL Query WithInstance Config Description
user The username of the user connecting
personal-access-token An access token from Gitlab (https://<gitlab_url>/profile/personal_access_tokens)
gitlab_url url of the gitlab server
project_id id of the repository
path path in repo to migrations
ref (optional) can be a SHA, branch, or tag

Documentation

Index

Constants

View Source
const DefaultMaxItemsPerPage = 100

Variables

View Source
var (
	ErrNoUserInfo       = fmt.Errorf("no username:token provided")
	ErrNoAccessToken    = fmt.Errorf("no access token")
	ErrInvalidHost      = fmt.Errorf("invalid host")
	ErrInvalidProjectID = fmt.Errorf("invalid project id")
	ErrInvalidResponse  = fmt.Errorf("invalid response")
)

Functions

func WithInstance

func WithInstance(client *gitlab.Client, config *Config) (source.Driver, error)

Types

type Config

type Config struct {
}

type Gitlab

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

func (*Gitlab) Close

func (g *Gitlab) Close() error

func (*Gitlab) First

func (g *Gitlab) First() (version uint, er error)

func (*Gitlab) Next

func (g *Gitlab) Next(version uint) (nextVersion uint, err error)

func (*Gitlab) Open

func (g *Gitlab) Open(url string) (source.Driver, error)

func (*Gitlab) Prev

func (g *Gitlab) Prev(version uint) (prevVersion uint, err error)

func (*Gitlab) ReadDown

func (g *Gitlab) ReadDown(version uint) (r io.ReadCloser, identifier string, err error)

func (*Gitlab) ReadUp

func (g *Gitlab) ReadUp(version uint) (r io.ReadCloser, identifier string, err error)

Jump to

Keyboard shortcuts

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