library

package
v0.0.0-...-cca4c9a Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2024 License: Apache-2.0 Imports: 23 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CloneRemoteStack

func CloneRemoteStack(git *schema.Git, path string, verbose bool) (err error)

CloneRemoteStack downloads the stack version from a git repo outside of the registry by cloning then removing the local .git folder. When git.SubDir is set, fetches specified subdirectory only.

func CreateIndexFile

func CreateIndexFile(index []schema.Schema, indexFilePath string) error

CreateIndexFile creates index file in disk

func DownloadStackFromGit

func DownloadStackFromGit(git *schema.Git, path string, verbose bool) ([]byte, error)

DownloadStackFromGit downloads the stack from a git repo then adds folder contents into a zip archive, returns byte array of zip file and error if occurs otherwise is nil. If git.SubDir is set, then zip file will contain contents of the specified subdirectory instead of the whole downloaded git repo.

func DownloadStackFromZipUrl

func DownloadStackFromZipUrl(zipUrl string, subDir string, path string) ([]byte, error)

DownloadStackFromZipUrl downloads the zip file containing the stack at a given url, uses default filesystem

func GenerateIndexStruct

func GenerateIndexStruct(registryDirPath string, force bool) ([]schema.Schema, error)

GenerateIndexStruct parses registry then generates index struct according to the schema

func GitSubDir

func GitSubDir(srcPath, destinationPath, subDir string) error

GitSubDir handles subDir for git components using the default filesystem

func SortVersionByDescendingOrder

func SortVersionByDescendingOrder(versions []schema.Version) []schema.Version

func StartSignalWatcher

func StartSignalWatcher(watchSignals []os.Signal, handle func(receivedSignal os.Signal))

StartSignalWatcher watches for signals and handles the situation before exiting the program

func ZipDir

func ZipDir(src string, dst string) error

ZipDir creates a zip file from a given directory specified by the src argument into a zip archive specified by the *dst* argument, uses default filesystem

Types

type IconUrlBrokenError

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

func (*IconUrlBrokenError) Error

func (e *IconUrlBrokenError) Error() string

type MissingArchError

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

MissingArchError is an error if the architecture list is empty

func (*MissingArchError) Error

func (e *MissingArchError) Error() string

type MissingProviderError

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

MissingProviderError is an error if the provider field is missing

func (*MissingProviderError) Error

func (e *MissingProviderError) Error() string

type MissingSupportUrlError

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

MissingSupportUrlError is an error if the supportUrl field is missing

func (*MissingSupportUrlError) Error

func (e *MissingSupportUrlError) Error() string

type Semver

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

Jump to

Keyboard shortcuts

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