Documentation
¶
Index ¶
- type CommitFile
- type Engine
- func (e *Engine) Checkin(files []WriteFile, message string) error
- func (e *Engine) Close() error
- func (e *Engine) CommitFiles(files []CommitFile, message, user string, parentRID int64, ...) (int64, string, error)
- func (e *Engine) ListFiles(version string) ([]FileEntry, error)
- func (e *Engine) ListFilesAt(rid int64) ([]FileEntry, error)
- func (e *Engine) ReadFile(rid int64, path string) ([]byte, error)
- func (e *Engine) Repo() *libfossil.Repo
- func (e *Engine) ResolveVersion(version string) (int64, error)
- func (e *Engine) Stat(version string) (*RepoInfo, error)
- type FileEntry
- type RepoInfo
- type WriteFile
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CommitFile ¶
CommitFile describes a single file in a Fossil check-in: name, content, and an optional executable-bit marker ("x" or "").
type Engine ¶
type Engine struct {
// contains filtered or unexported fields
}
Engine provides Fossil repository operations used by the VFS layer. Thin wrapper over libfossil's public API.
func (*Engine) Checkin ¶
Checkin creates a new commit with the given files and message. Preserved for the original FUSE-shape callers; new callers should use CommitFiles.
func (*Engine) CommitFiles ¶
func (e *Engine) CommitFiles(files []CommitFile, message, user string, parentRID int64, partialManifest bool) (int64, string, error)
CommitFiles creates a new check-in with the given files. When partialManifest is false, files tracked at parentRID but absent from files are carried forward automatically (Fossil's "fossil ci" semantics). When true, the new manifest contains only the provided files — used by the VFS overlay drain when the commit includes deletions.
func (*Engine) ListFiles ¶
ListFiles returns metadata for all files in the given version. Version can be "tip", "trunk", a UUID prefix, or empty (defaults to tip).
func (*Engine) ListFilesAt ¶
ListFilesAt returns file metadata for the given checkin RID.
func (*Engine) ReadFile ¶
ReadFile returns the content of a single file at the given checkin RID. Walks the delta chain internally; no disk checkout is required.
func (*Engine) Repo ¶
Repo returns the underlying libfossil repo handle. Exposed for the VFS layer's overlay table (a SQLite table living inside the same agent repo file). Treat as an escape hatch — prefer the typed methods above.
func (*Engine) ResolveVersion ¶
ResolveVersion resolves a symbolic version ("tip", "trunk", a branch name, a UUID, or a UUID prefix) to a numeric checkin RID.