git

package
v0.39.3 Latest Latest
Warning

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

Go to latest
Published: Jun 10, 2021 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package git contains git repo cloning functions similar to Kustomize's

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RepoSpec

type RepoSpec struct {
	// Host, e.g. github.com
	Host string

	// orgRepo name (organization/repoName),
	// e.g. kubernetes-sigs/kustomize
	OrgRepo string

	// Dir where the orgRepo is cloned to.
	Dir string

	// Relative path in the repository, and in the cloneDir,
	// to a Kustomization.
	Path string

	// Branch or tag reference.
	Ref string

	// e.g. .git or empty in case of _git is present
	GitSuffix string
}

RepoSpec specifies a git repository and a branch and path therein.

func (RepoSpec) AbsPath

func (rs RepoSpec) AbsPath() string

AbsPath is the absolute path to the subdirectory

func (*RepoSpec) CloneSpec

func (rs *RepoSpec) CloneSpec() string

CloneSpec returns the string to pass to git to clone

func (*RepoSpec) RepoRef added in v0.39.3

func (rs *RepoSpec) RepoRef() string

Jump to

Keyboard shortcuts

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