state

package
v0.1.5 Latest Latest
Warning

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

Go to latest
Published: Jul 31, 2024 License: AGPL-3.0 Imports: 4 Imported by: 0

Documentation

Overview

Package state implements state tracking for the remarkabledayone utility.

Index

Constants

View Source
const FileName = "state.yml"

Variables

This section is empty.

Functions

This section is empty.

Types

type State

type State struct {

	// SyncedPages is a map of synced page IDs.
	SyncedPages map[string]struct{} `yaml:"synced_pages"`
	// contains filtered or unexported fields
}

func Load

func Load(log *slog.Logger) *State

Load loads the state from disk. If an error occurs, it will return a new state.

func (*State) Save

func (s *State) Save() error

Save saves the state to disk if there was a path provided when it was created. Top-level directories are created if they don't exist.

Jump to

Keyboard shortcuts

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