lock

package
v1.235.0 Latest Latest
Warning

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

Go to latest
Published: Nov 26, 2026 License: Apache-2.0 Imports: 16 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package lock records reproducible plugin selections independently of local overrides.

Index

Constants

View Source
const Kind = "AtmosPluginLock"

Variables

This section is empty.

Functions

func CheckDeclarations

func CheckDeclarations(file *File, declarations map[string]schema.PluginPackage) error

CheckDeclarations enforces exact dependency/lock agreement in frozen mode.

func CheckRelease

func CheckRelease(entry *Entry, release *pluginoci.Release) error

CheckRelease prevents tag movement or layout substitution from changing a lock.

func Path

func Path(project string) string

Path returns the project lock location beside its root configuration.

func Save

func Save(project string, file *File) error

Save atomically writes a prepared lock. The caller owns the transaction lock.

Types

type Entry

type Entry struct {
	Plugin       string            `yaml:"plugin" json:"plugin"`
	Source       string            `yaml:"source" json:"source"`
	Constraint   string            `yaml:"constraint" json:"constraint"`
	Version      string            `yaml:"version" json:"version"`
	IndexDigest  string            `yaml:"index_digest" json:"index_digest"`
	Platforms    map[string]string `yaml:"platforms" json:"platforms"`
	Runtime      manifest.Runtime  `yaml:"runtime" json:"runtime"`
	Exports      []Export          `yaml:"exports" json:"exports"`
	Verification Verification      `yaml:"verification" json:"verification"`
}

Entry contains the source constraint and the exact release/platform digests.

type Export

type Export struct {
	Capability string `yaml:"capability" json:"capability"`
	Name       string `yaml:"name" json:"name"`
}

Export identifies one statically validated extension.

type File

type File = atmosmanifest.Manifest[Spec]

File is a standard versioned Atmos manifest.

func Load

func Load(project string) (*File, error)

Load reads an optional lock and validates all entries without network access.

func New

func New() *File

New creates an empty release lock.

type Spec

type Spec struct {
	LockVersion  int              `yaml:"lock_version" json:"lock_version"`
	GeneratedAt  time.Time        `yaml:"generated_at" json:"generated_at"`
	AtmosVersion string           `yaml:"atmos_version" json:"atmos_version"`
	Packages     map[string]Entry `yaml:"packages" json:"packages"`
}

Spec records immutable release choices; timestamps never affect frozen equality.

type Verification

type Verification struct {
	Signature string `yaml:"signature" json:"signature"`
	Identity  string `yaml:"identity,omitempty" json:"identity,omitempty"`
	Issuer    string `yaml:"issuer,omitempty" json:"issuer,omitempty"`
}

Verification distinguishes integrity from publisher identity.

Jump to

Keyboard shortcuts

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