state

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: May 7, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

Package state stores local-only skeeper operational state.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Entry

type Entry struct {
	Time      time.Time `json:"time"`
	Reason    string    `json:"reason"`
	MainSHA   string    `json:"main_sha"`
	Namespace string    `json:"namespace,omitempty"`
}

Entry records a queued sync retry.

type Store

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

Store manages queue and log files under .git/skeeper.

func New

func New(dir string) *Store

New returns a Store rooted at dir.

func (*Store) AppendLog

func (s *Store) AppendLog(line string) error

AppendLog writes one human-readable sync log line.

func (*Store) ClearQueue

func (s *Store) ClearQueue() error

ClearQueue removes queued retries.

func (*Store) Enqueue

func (s *Store) Enqueue(entry Entry) error

Enqueue appends a retry entry.

func (*Store) Queue

func (s *Store) Queue() ([]Entry, error)

Queue returns all queued sync entries.

Jump to

Keyboard shortcuts

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