git

package
v0.2.3 Latest Latest
Warning

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

Go to latest
Published: Jan 24, 2022 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrUpdatedTooRecently = errors.New("updated too recently")

Functions

func CloneRepository

func CloneRepository(url string, sshPrivateKey string)

func GetRepo added in v0.1.7

func GetRepo() *git.Repository

This function returns the current repository object

func GetRepoDir

func GetRepoDir() string

This function returns the current repository path as a string.

func GetRepoHeadCommit

func GetRepoHeadCommit() (*gitobject.Commit, error)

This function returns (*object.Commit, error). The Git Commit Object is the result of resolving HEAD on the config repository used by the scheduler.. see https://pkg.go.dev/github.com/go-git/go-git/v5@v5.1.0/plumbing/object?tab=doc#Commit Error is nil if OK.

func RefreshRepository

func RefreshRepository() error

This function refreshes the git Worktree containing the configuration of the scheduler. It's basically running the equivalent of 'git pull'.

Types

This section is empty.

Jump to

Keyboard shortcuts

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