mod

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jan 24, 2026 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const ModuleManifestFilename = "bagl.mod"

Variables

View Source
var ErrInvalidManifest = errors.New("invalid manifest")

Functions

This section is empty.

Types

type BuildList

type BuildList map[VersionedModule]bool

func ConstructBuildList

func ConstructBuildList(g BuildListGraph, root VersionedModule) (BuildList, error)

func (BuildList) ToSlice

func (s BuildList) ToSlice() []VersionedModule

type BuildListGraph

type BuildListGraph interface {
	GetDependencies(vmod VersionedModule) ([]VersionedModule, error)
}

type Manifest

type Manifest struct {
	Module string `yaml:"module"`
}

func ParseManifest

func ParseManifest(buf []byte) (*Manifest, error)

func ReadManifest

func ReadManifest(f fs.FS, rootDir string) (*Manifest, error)

type Module

type Module struct {
	Name string
	Path string
}

type Package

type Package struct {
	Name   string
	Path   string
	Module *Module
}

type PackageResolver

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

func NewPackageResolver

func NewPackageResolver() *PackageResolver

func (*PackageResolver) AddModule

func (r *PackageResolver) AddModule(module *Module) error

func (*PackageResolver) ResolvePackage

func (r *PackageResolver) ResolvePackage(packageName string) (*Package, error)

type Requirement

type Requirement struct {
	ModuleID string
	Version  Version
}

type Version

type Version struct {
	Major int
	Minor int
	Patch int
}

func (Version) Compare

func (v Version) Compare(v2 Version) int

type VersionedModule

type VersionedModule struct {
	ModuleID string
	Version  Version
}

Jump to

Keyboard shortcuts

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