workspace

package
v0.0.0-...-0e469d2 Latest Latest
Warning

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

Go to latest
Published: Jul 28, 2022 License: GPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const SettingsPath = ".guest/workspace.json"

Variables

This section is empty.

Functions

This section is empty.

Types

type ExportOptions

type ExportOptions struct {
	Ignore []string
}

type Folder

type Folder struct {
	Description string `json:"description"`

	Variables   map[string]string      `json:"variables,omitempty" yaml:"variables,omitempty"`
	Scripts     map[string]string      `json:"scripts,omitempty" yaml:"scripts,omitempty"`
	HandOptions map[string]interface{} `json:"options,omitempty" yaml:"options,omitempty"`
}

func (*Folder) Load

func (f *Folder) Load(data []byte, format settings.SettingsFormat) error

type Workspace

type Workspace struct {
	Folder

	PathInfo  *storage.StoragePathInfo
	VirtualFs storage.Storage
	// contains filtered or unexported fields
}

func FromStorage

func FromStorage(storageName, path string) (*Workspace, error)

func NewWorkspace

func NewWorkspace() (*Workspace, error)

func (*Workspace) Export

func (w *Workspace) Export(destPath string, destStorage storage.Storage, opts *ExportOptions) error

func (*Workspace) Knock

func (w *Workspace) Knock(path string, externalVars map[string]string) (*knock.Result, error)

func (*Workspace) Load

func (w *Workspace) Load() error

func (*Workspace) LoadFolders

func (w *Workspace) LoadFolders(endPath string) ([]*Folder, error)

func (*Workspace) LoadVariables

func (w *Workspace) LoadVariables(folders []*Folder, external map[string]string) (map[string]string, error)

func (*Workspace) Save

func (w *Workspace) Save() error

func (*Workspace) Validate

func (w *Workspace) Validate() error

Jump to

Keyboard shortcuts

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