git

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: May 7, 2024 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Git

type Git struct{}

func (Git) Clone

func (g Git) Clone(url, branch, path string) error

func (Git) Fetch

func (g Git) Fetch(path string) error

func (Git) GetCurrentCommit

func (g Git) GetCurrentCommit(path string) (string, error)

func (Git) OpenOrClone

func (g Git) OpenOrClone(url, branch, path string) error

func (Git) Reset

func (g Git) Reset(path, refname string) error

type Repository

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

func NewRepository

func NewRepository(path string, lock *lock.Lock, dep *vending.Dependency) *Repository

func (*Repository) Fetch

func (r *Repository) Fetch() error

func (*Repository) GetCurrentCommit

func (r *Repository) GetCurrentCommit() (string, error)

func (*Repository) Lock

func (r *Repository) Lock() (*lock.Lock, error)

func (*Repository) OpenOrClone

func (r *Repository) OpenOrClone() error

func (*Repository) Path

func (r *Repository) Path() string

func (*Repository) Reset

func (r *Repository) Reset(refname string) error

func (*Repository) WalkDir

func (r *Repository) WalkDir(fn fs.WalkDirFunc) error

Jump to

Keyboard shortcuts

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