toolchain

package
v0.20.0 Latest Latest
Warning

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

Go to latest
Published: Oct 22, 2026 License: MIT Imports: 16 Imported by: 0

Documentation

Overview

Package toolchain implements the private storage layout for Go releases.

Index

Constants

View Source
const Prefix = ".athens/toolchains/v1/"

Prefix is reserved for release objects, never module catalog entries.

Variables

This section is empty.

Functions

This section is empty.

Types

type Objects

type Objects interface {
	Open(ctx context.Context, key string) (storage.SizeReadCloser, error)
	Create(ctx context.Context, key string, body io.ReadSeeker, size int64) error
	Keys(ctx context.Context, prefix string) ([]string, error)
	Delete(ctx context.Context, key string) error
}

Objects is private backend plumbing. Create atomically publishes a complete object and returns KindAlreadyExists if the key already exists. Bodies passed to Create are seekable, with a known length.

type Store

type Store struct{ Objects Objects }

Store implements the public release contracts using atomic backend objects.

func (*Store) Archive

func (s *Store) Archive(ctx context.Context, source, filename string) (storage.ArchiveInfo, storage.SizeReadCloser, error)

func (*Store) DeleteArchive

func (s *Store) DeleteArchive(ctx context.Context, source, filename string) error

func (*Store) ListArchives

func (s *Store) ListArchives(ctx context.Context, source string) ([]storage.ArchiveInfo, error)

func (*Store) Releases

func (s *Store) Releases(ctx context.Context, source string) (*storage.ReleaseList, error)

func (*Store) SaveArchive

func (s *Store) SaveArchive(ctx context.Context, source string, info storage.ArchiveInfo, body io.Reader) error

func (*Store) SaveReleases

func (s *Store) SaveReleases(ctx context.Context, source string, list *storage.ReleaseList) error

Jump to

Keyboard shortcuts

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