Versions in this module Expand all Collapse all v0 v0.9.0 Oct 28, 2026 v0.8.0 Oct 26, 2026 Changes in this version + var ErrFull = errors.New("memory: scope full") + var ErrInvalid = errors.New("memory: invalid entry") + var ErrNotFound = errors.New("memory: entry not found") + var ErrTooLarge = errors.New("memory: entry too large") + func CheckID(id string) error + func ID(title string, taken func(string) bool) string + func Index(entries []Entry, trusted func(Entry) bool) string + func ProjectKey(root string) string + type Entry struct + Author string + Body string + Created time.Time + ID string + SHA256 string + Scope Scope + Sensitive bool + Title string + type Options struct + DataDir string + Now func() time.Time + Project bool + RetentionDays int + Root string + type Scope string + const Global + const Project + const User + func ParseScope(s string) (Scope, error) + type Store struct + func Open(o Options) *Store + func (s *Store) Check(e Entry) error + func (s *Store) Expires(e Entry) time.Time + func (s *Store) Forget(scope Scope, id string) error + func (s *Store) Get(scope Scope, id string) (Entry, error) + func (s *Store) List() (entries []Entry, notices []string) + func (s *Store) Path(sc Scope, id string) string + func (s *Store) Purge() (gone []Entry, err error) + func (s *Store) Put(e Entry) (Entry, error) + func (s *Store) Touch(e Entry) error + func (s *Store) Trust(e Entry) error + func (s *Store) Trusted(e Entry) bool + func (s *Store) TrustedFunc() func(Entry) bool