Skip to main content

gc_legacy

Function gc_legacy 

Source
pub fn gc_legacy(workspace: &Path) -> Result<u64, SessionStoreError>
👎Deprecated:

removes files migration never imports; re-run migrate_legacy(workspace, true) instead

Expand description

Remove the legacy history/ and logs/ directories after they have been imported into the unified store by crate::migrate_legacy.

Returns the number of bytes freed. The legacy checkpoints/ directory is intentionally left in place until /revert is rewired to the unified store; callers should confirm revert behavior before deleting it manually.

Deprecated: this removes whole directories, including files migration never imports (unrelated, nested, and symlinked entries). Re-run crate::migrate_legacy with remove_legacy = true instead: retries reuse exact imports and remove only verified sources.