Documentation
¶
Index ¶
- Constants
- Variables
- func Commit(ctx context.Context, opts Options, message string) (bool, error)
- func CreateImmutableTag(ctx context.Context, opts Options) (string, error)
- func EnsureRepo(ctx context.Context, opts Options) error
- func ManifestAlreadyImported(ctx context.Context, s *store.Store, manifest Manifest) bool
- func MarkImported(ctx context.Context, s *store.Store, manifest Manifest) error
- func NeedsImport(ctx context.Context, s *store.Store, staleAfter time.Duration) bool
- func Pull(ctx context.Context, opts Options) error
- func Push(ctx context.Context, opts Options) error
- func ValidateTag(ctx context.Context, opts Options) error
- type Manifest
- func Export(ctx context.Context, s *store.Store, opts Options) (Manifest, error)
- func Import(ctx context.Context, s *store.Store, opts Options) (Manifest, error)
- func ImportAt(ctx context.Context, s *store.Store, opts Options, ref string) (Manifest, error)
- func ImportIfChanged(ctx context.Context, s *store.Store, opts Options) (Manifest, bool, error)
- func ReadManifest(repoPath string) (Manifest, error)
- type MediaFileManifest
- type MediaManifest
- type Options
- type SyncState
- type TableManifest
Constants ¶
View Source
const (
ManifestName = "manifest.json"
)
Variables ¶
View Source
var ErrNoManifest = errors.New("share manifest not found")
View Source
var SnapshotTables = []string{
"workspaces",
"channels",
"users",
"messages",
"message_files",
"message_events",
"message_mentions",
"sync_state",
"embedding_jobs",
}
Functions ¶
func CreateImmutableTag ¶ added in v0.7.3
func ManifestAlreadyImported ¶
func NeedsImport ¶
Types ¶
type Manifest ¶
type Manifest struct {
Version int `json:"version"`
GeneratedAt time.Time `json:"generated_at"`
Tables []TableManifest `json:"tables"`
Media *MediaManifest `json:"media,omitempty"`
Files map[string]string `json:"files,omitempty"`
}
func ImportAt ¶ added in v0.7.3
ImportAt restores a snapshot from a Git ref without changing the share checkout.
func ImportIfChanged ¶
func ReadManifest ¶
type MediaFileManifest ¶
type MediaManifest ¶
type MediaManifest struct {
Files int `json:"files"`
Bytes int64 `json:"bytes"`
Items []MediaFileManifest `json:"items,omitempty"`
}
Click to show internal directories.
Click to hide internal directories.