Documentation ¶
Index ¶
- Constants
- func AddTagPrefix(tag string) string
- func Ask(question, expectedResponse string, retries int) (answer string, success bool, err error)
- func CopyDirContentsLocal(src, dst string) error
- func CopyFileLocal(src, dst string, required bool) error
- func EnvDefault(key, def string) string
- func Exists(path string) bool
- func FakeGOPATH(srcDir string) (string, error)
- func IsEnvSet(key string) bool
- func MoreRecent(a, b string) (bool, error)
- func PackagesAvailable(packages ...string) (bool, error)
- func ReadFileFromGzippedTar(tarPath, filePath string) (io.Reader, error)
- func RemoveAndReplaceDir(path string) error
- func SemverToTagString(tag semver.Version) string
- func TagStringToSemver(tag string) (semver.Version, error)
- func TrimTagPrefix(tag string) string
Constants ¶
const (
TagPrefix = "v"
)
Variables ¶
This section is empty.
Functions ¶
func AddTagPrefix ¶ added in v0.2.1
func CopyDirContentsLocal ¶ added in v0.2.4
CopyDirContentsLocal copies local directory contents from one local location to another.
func CopyFileLocal ¶ added in v0.2.4
CopyFileLocal copies a local file from one local location to another.
func EnvDefault ¶ added in v0.2.1
EnvDefault returns either the provided environment variable for the given `key` or the default value `def` if not set.
func FakeGOPATH ¶
FakeGOPATH creates a temp directory, links the base directory into it and sets the GOPATH environment variable to it.
func MoreRecent ¶ added in v0.2.1
MoreRecent determines if file at path a was modified more recently than file at path b. If one file does not exist, the other will be treated as most recent. If both files do not exist or an error occurs, an error is returned.
func PackagesAvailable ¶ added in v0.2.4
PackagesAvailable takes a slice of packages and determines if they are installed on the host OS. Replaces common::check_packages.
func ReadFileFromGzippedTar ¶ added in v0.2.1
ReadFileFromGzippedTar opens a tarball and reads contents of a file inside.
func RemoveAndReplaceDir ¶ added in v0.2.4
RemoveAndReplaceDir removes a directory and its contents then recreates it.
func SemverToTagString ¶ added in v0.2.4
func TrimTagPrefix ¶ added in v0.2.1
Types ¶
This section is empty.