gitrepo

package
v0.5.1 Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2021 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsNotFound

func IsNotFound(err error) bool

IsNotFound asserts notFoundError.

Types

type Config

type Config struct {
	GitHubToken string
}

type Repo

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

func New

func New(config Config) (*Repo, error)

func (*Repo) ShallowClone

func (r *Repo) ShallowClone(ctx context.Context, url string, ref plumbing.ReferenceName) (*Store, error)

func (*Repo) ShallowCloneBranch

func (r *Repo) ShallowCloneBranch(ctx context.Context, url, branch string) (*Store, error)

func (*Repo) ShallowCloneTag

func (r *Repo) ShallowCloneTag(ctx context.Context, url, tag string) (*Store, error)

type Store

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

func (*Store) ReadDir

func (s *Store) ReadDir(dirpath string) ([]os.FileInfo, error)

func (*Store) ReadFile

func (s *Store) ReadFile(path string) ([]byte, error)

Jump to

Keyboard shortcuts

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