Versions in this module Expand all Collapse all v0 v0.3.1 Feb 22, 2026 v0.3.0 Feb 8, 2026 Changes in this version + const MaxNameLen + var ErrExists = errors.New("a mark already exists by that name") + var ErrNotExist = errors.New("mark does not exist") + func CheckName(name string) error + func CloneMark(ctx context.Context, st SpaceTx, from, to string) error + func ForEach(ctx context.Context, stx SpaceTx, span Span, fn func(string) error) (retErr error) + func GotFS(cfg DSConfig) *gotfs.Machine + func GotVC(cfg DSConfig) *gotvc.Machine[Payload] + func History(ctx context.Context, vcmach *VCMach, s stores.Reading, snapRef gdat.Ref, ...) error + func IsExists(err error) bool + func IsNotExist(err error) bool + func SortAnnotations(s []Annotation) + func Sync(ctx context.Context, src, dst *MarkTx, force bool) error + func SyncSpaces(ctx context.Context, task SyncSpacesTask) error + func TestSpace(t *testing.T, newSpace func(t testing.TB) Space) + func TestSync(t *testing.T, setup func(testing.TB) Space) + func ViewSnapshot(ctx context.Context, stx SpaceTx, se SnapExpr, fn func(vctx *ViewCtx) error) error + type Annotation struct + Key string + Value string + func GetAnnotation(as []Annotation, key string) (ret []Annotation) + type ChunkingConfig struct + CD *Chunking_CDConfig + Max *Chunking_Fixed + type Chunking_CDConfig struct + MaxSize int + MeanSize int + type Chunking_Fixed struct + Max uint32 + Min uint32 + type DSConfig struct + GotFS FSConfig + Salt Salt + func DefaultConfig(public bool) DSConfig + func (cfg DSConfig) Hash() [32]byte + func (cfg DSConfig) Marshal(out []byte) []byte + type ErrInvalidName struct + Name string + Reason string + func (e ErrInvalidName) Error() string + type ErrRefIntegrity struct + Ref gdat.Ref + Store string + func (e ErrRefIntegrity) Error() string + type FSConfig struct + Data ChunkingConfig + Metadata Chunking_CDConfig + type FSMach = gotfs.Machine + type Info struct + Annotations []Annotation + Config DSConfig + CreatedAt tai64.TAI64 + func CreateIfNotExists(ctx context.Context, stx SpaceTx, k string, cfg Metadata) (*Info, error) + func (i Info) AsMetadata() Metadata + func (i Info) Clone() Info + type MarkTx struct + func NewMarkTx(ctx context.Context, stx SpaceTx, name string) (*MarkTx, error) + func (b *MarkTx) GotFS() *gotfs.Machine + func (b *MarkTx) GotVC() *VCMach + func (b *MarkTx) History(ctx context.Context, fn func(ref gdat.Ref, snap Snap) error) error + func (b *MarkTx) Info() Info + func (b *MarkTx) Load(ctx context.Context, dst *gdat.Ref) (bool, error) + func (b *MarkTx) LoadFS(ctx context.Context, dst *gotfs.Root) (bool, error) + func (m *MarkTx) Apply(ctx context.Context, fn func([3]stores.RW, gdat.Ref) (gdat.Ref, error)) error + func (m *MarkTx) Config() DSConfig + func (m *MarkTx) Modify(ctx context.Context, fn func(mctx ModifyCtx) (*Snap, error)) error + func (m *MarkTx) Save(ctx context.Context, ref gdat.Ref) error + func (mt *MarkTx) LoadSnap(ctx context.Context, dst *Snap) (bool, error) + func (mtx *MarkTx) FSRO() [2]stores.Reading + func (mtx *MarkTx) FSRW() [2]stores.RW + func (mtx *MarkTx) RO() [3]stores.Reading + func (mtx *MarkTx) VCRO() stores.Reading + func (mtx *MarkTx) VCRW() stores.RW + func (mtx *MarkTx) WO() [3]stores.Writing + type Metadata struct + Annotations []Annotation + Config DSConfig + func (c Metadata) AsInfo() Info + func (c Metadata) Clone() Metadata + type ModifyCtx struct + FS *FSMach + Root *Snap + Stores [3]stores.RW + VC *VCMach + func (mctx *ModifyCtx) Sync(ctx context.Context, srcs [3]stores.Reading, root Snap) error + type Payload struct + Aux []byte + Root gotfs.Root + func ParsePayload(data []byte) (Payload, error) + func (p *Payload) Unmarshal(data []byte) error + func (p Payload) Marshal(out []byte) []byte + type Salt [32]byte + func (s *Salt) String() string + func (s *Salt) UnmarshalText(data []byte) error + func (s Salt) MarshalText() ([]byte, error) + type Snap = gotvc.Vertex[Payload] + func GetSnapshot(ctx context.Context, s stores.Reading, ref gdat.Ref) (*Snap, error) + type SnapExpr interface + GetSpace func() string + Resolve func(ctx context.Context, stx SpaceTx) (*gdat.Ref, error) + func ParseSnapExpr(x string) (SnapExpr, error) + type SnapExpr_Exact struct + Ref gdat.Ref + Space string + func ParseSnap_Exact(x string) (*SnapExpr_Exact, error) + func (se *SnapExpr_Exact) GetSpace() string + func (se *SnapExpr_Exact) Resolve(ctx context.Context, tx SpaceTx) (*gdat.Ref, error) + type SnapExpr_Mark struct + Name string + Space string + func ParseSnap_Mark(x string) (*SnapExpr_Mark, error) + func (se SnapExpr_Mark) GetSpace() string + func (se SnapExpr_Mark) Resolve(ctx context.Context, tx SpaceTx) (*gdat.Ref, error) + func (se SnapExpr_Mark) String() string + type SnapExpr_Offset struct + Offset uint + X SnapExpr + type SnapInfo struct + AuthoredAt tai64.TAI64 + Authors []inet256.ID + Message string + type Space interface + Do func(ctx context.Context, modify bool, fn func(SpaceTx) error) error + type SpaceTx interface + All func(context.Context) iter.Seq2[string, error] + Create func(ctx context.Context, name string, md Metadata) (*Info, error) + Delete func(ctx context.Context, name string) error + GetTarget func(ctx context.Context, name string, dst *gdat.Ref) (bool, error) + Inspect func(ctx context.Context, name string) (*Info, error) + SetMetadata func(ctx context.Context, name string, md Metadata) error + SetTarget func(ctx context.Context, name string, ref gdat.Ref) error + Stores func() [3]stores.RW + type Span struct + Begin string + End string + func TotalSpan() Span + func (s Span) Contains(x string) bool + type SyncSpacesTask struct + Dst Space + Filter func(string) bool + MapName func(string) string + Src Space + type VCMach = gotvc.Machine[Payload] + type ViewCtx struct + FS *FSMach + Root *Snap + Stores [3]stores.Reading + Target gdat.Ref + VC *VCMach + func (vc *ViewCtx) FSRO() [2]stores.Reading