Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Fetch ¶
func Fetch(logger *zap.SugaredLogger, spec FetchSpec) error
Fetch fetches the specified git repository at the revision into path, using the refspec to fetch if provided.
func ShowCommit ¶ added in v0.12.0
func ShowCommit(logger *zap.SugaredLogger, revision, path string) (string, error)
ShowCommit calls "git show ..." to get the commit SHA for the given revision
Types ¶
type FetchSpec ¶ added in v0.10.0
type FetchSpec struct { URL string Revision string Refspec string Path string Depth uint Submodules bool SSLVerify bool HTTPProxy string HTTPSProxy string NOProxy string SparseCheckoutDirectories string }
FetchSpec describes how to initialize and fetch from a Git repository.
Click to show internal directories.
Click to hide internal directories.