workspace

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Dec 22, 2025 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package workspace provides workspace discovery and management for monox.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Init

func Init(path string, name string) error

Init initializes a new workspace.

Types

type Workspace

type Workspace struct {
	Root     string
	Config   *api.WorkspaceConfig
	Projects map[string]*api.Project
}

Workspace represents a monox workspace.

func Discover

func Discover(startPath string) (*Workspace, error)

Discover finds and loads a workspace from the given path.

func (*Workspace) GetProject

func (w *Workspace) GetProject(name string) (*api.Project, bool)

GetProject returns a project by name.

func (*Workspace) GetProjectByPath

func (w *Workspace) GetProjectByPath(path string) (*api.Project, bool)

GetProjectByPath returns a project by path.

func (*Workspace) GetProjectsByLanguage

func (w *Workspace) GetProjectsByLanguage(language string) []*api.Project

GetProjectsByLanguage returns projects with a specific language.

func (*Workspace) GetProjectsByTag

func (w *Workspace) GetProjectsByTag(tag string) []*api.Project

GetProjectsByTag returns projects matching a tag.

func (*Workspace) ListProjects

func (w *Workspace) ListProjects() []*api.Project

ListProjects returns all projects.

func (*Workspace) Validate

func (w *Workspace) Validate() []error

Validate validates the workspace configuration.

Jump to

Keyboard shortcuts

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