Skip to main content

Crate khive_vcs

Crate khive_vcs 

Source
Expand description

KG versioning — snapshots, branches, and remote sync.

Implements the versioning model from ADR-015 and the implementation details from ADR-042: content-addressed snapshots, named branch pointers, and the remote push/pull protocol.

§Crate layout

  • typesKgSnapshot, KgBranch, SnapshotId, RemoteConfig
  • hash — canonical JSON serialization + SHA-256 snapshot hashing
  • snapshotcommit() operation
  • branchbranch(), checkout(), list_branches()
  • loglog() operation (snapshot history)
  • merge_engineMergeEngine trait + NoOpMergeEngine
  • errorVcsError type

Re-exports§

pub use error::VcsError;
pub use merge_engine::MergeEngine;
pub use merge_engine::MergeResult;
pub use merge_engine::MergeStrategy;
pub use merge_engine::NoOpMergeEngine;
pub use types::KgBranch;
pub use types::KgSnapshot;
pub use types::RemoteAuth;
pub use types::RemoteConfig;
pub use types::SnapshotId;

Modules§

branch
branch() and checkout() operations (ADR-042 §4, ADR-015 §D.2).
error
Error types for the VCS layer.
hash
Canonical JSON serialization and SHA-256 snapshot hashing (ADR-042 §1).
log
log() operation — list snapshot history for a branch (ADR-015 log tool).
merge_engine
MergeEngine trait — pluggable merge implementation (ADR-042 §3).
migrations
SQL migrations for the VCS layer (ADR-042 §2).
snapshot
commit() operation — snapshot the current namespace state (ADR-042 §2, ADR-015 §D.1).
types
Core versioning types: SnapshotId, KgSnapshot, KgBranch, RemoteConfig.