meta

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Jan 26, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Save

func Save(owner, repo string, meta *Meta) error

Save saves metadata for a repository with atomic write.

Types

type Meta

type Meta struct {
	Sync *SyncTimestamps `yaml:"sync,omitempty"`
}

Meta is the root structure for the metadata file. It allows for future extensibility beyond sync timestamps.

func Load

func Load(owner, repo string) (*Meta, error)

Load loads metadata for a repository. Returns an empty Meta if the file doesn't exist.

type SyncTimestamps

type SyncTimestamps struct {
	Issues      *time.Time `yaml:"issues,omitempty"`
	Pulls       *time.Time `yaml:"pulls,omitempty"`
	Discussions *time.Time `yaml:"discussions,omitempty"`
	// Previous timestamps for --new flag (items updated since previous sync)
	PrevIssues      *time.Time `yaml:"prev_issues,omitempty"`
	PrevPulls       *time.Time `yaml:"prev_pulls,omitempty"`
	PrevDiscussions *time.Time `yaml:"prev_discussions,omitempty"`
}

SyncTimestamps stores the last sync timestamps for each item type.

Jump to

Keyboard shortcuts

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