workspace

package
v0.1.36 Latest Latest
Warning

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

Go to latest
Published: Aug 10, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const VSCodeFileExtension = ".code-workspace"

Variables

This section is empty.

Functions

This section is empty.

Types

type VSCode

type VSCode struct {
	// Folders represents a list of projects
	Folders []VSCodeFolder `json:"folders"`
}

VSCode represents the visual studio code .code-workspace file format

func (VSCode) ToJSON added in v0.0.4

func (vsc VSCode) ToJSON() (string, error)

ToJSON returns a string that can be used as the .code-workspace visual studio code workspace file

func (VSCode) WriteTo added in v0.0.4

func (vsc VSCode) WriteTo(workspacePath string, overwrite ...bool) error

WriteTo writes the current instance of VSCode as JSON into a .code-workspace file located at `workspacePath`. If `overwrite` is not specified, the function will fail to complete if an existing file is found

type VSCodeFolder

type VSCodeFolder struct {
	// Name is a logical user-defined label
	Name string `json:"name"`
	// Path is the absolute/relative path to the target project directory
	Path string `json:"path"`
}

VSCodeFolder represents a single folder in the visual studio code workspace format

type Workspace

type Workspace struct {
	Name         string                  `json:"name" yaml:"name"`
	Description  string                  `json:"description" yaml:"description"`
	Repositories []repository.Repository `json:"repositories" yaml:"repositories"`
}

Workspace represents a project-scoped set of code repos

func (Workspace) ToVSCode added in v0.0.4

func (ws Workspace) ToVSCode() (*VSCode, error)

Jump to

Keyboard shortcuts

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