lock

package
v0.3.2 Latest Latest
Warning

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

Go to latest
Published: Jul 31, 2018 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func UpdateLock

func UpdateLock(manifest *manifestType.Manifest, newLockFile *Lock) error

UpdateLock - update and write out a new lock file

func WriteLockToDisk

func WriteLockToDisk(lockFile *Lock) error

WriteLockToDisk - Write the Lock to disk

Types

type Lock

type Lock struct {
	// An array of the plugins we resolved and installed
	Plugins map[string]Plugin `yaml:"plugins"`
}

Lock - The Lock file

func FindAndLoadLock

func FindAndLoadLock() (lock *Lock)

FindAndLoadLock - Search the current directory for a Lock file, and load it If no lock is found, return an empty Lock

type Plugin

type Plugin struct {

	// The name of the plugin
	Name string `yaml:"name"`

	// The version downloaded
	Version string `yaml:"version"`

	// A map key by architecture of the resolved plugin
	Resolved map[string]PluginResolution
}

Plugin - Store the information of how the plugin was resolved and saved

type PluginResolution

type PluginResolution struct {

	// Exactly where it was downloaded from
	// A list of direct download urls for each architecture
	URL string `yaml:"urls"`

	OperatingSystem string `yaml:"operatingSystem"`

	Architecture string `yaml:"architecture"`

	// Exactly where it is store on disk, relative to the manifest file
	PathOnDisk string `yaml:"pathOnDisk"`

	// A sha256 hash of the plugin
	Hash string `yaml:"hash"`

	// A sha256 hash of the plugin archive (used to compare to the cache)
	ArchiveHash string `yaml:"archiveHash"`

	// The filename of the release archive
	ArchiveName string `yaml:"archiveName"`
}

PluginResolution -

Jump to

Keyboard shortcuts

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