Expand description
Git LFS (Large File Storage) operations and validation.
This module provides functions for detecting, validating, and managing Git LFS in repositories. It includes health checks, filter validation, and pointer file validation.
§Invariants
- Gracefully handles repositories without LFS (returns empty results, not errors)
- LFS pointer files are validated against the spec format
§What this does NOT handle
- Regular git operations (see git/status.rs, git/commit.rs)
- Repository cleanliness checks (see git/clean.rs)
Structs§
- LfsFilter
Status - LFS filter configuration status.
- LfsHealth
Report - Comprehensive LFS health check result.
- LfsStatus
Summary - Summary of LFS status from
git lfs status.
Enums§
- LfsPointer
Issue - Issue detected with an LFS pointer file.
Functions§
- check_
lfs_ health - Performs a comprehensive LFS health check.
- check_
lfs_ status - Runs
git lfs statusand parses the output to detect LFS issues. - filter_
modified_ lfs_ files - Filter status paths to only include LFS-tracked files.
- has_lfs
- Detects if Git LFS is initialized in the repository.
- list_
lfs_ files - Returns a list of LFS-tracked files in the repository.
- validate_
lfs_ filters - Validates that LFS smudge/clean filters are properly installed in git config.
- validate_
lfs_ pointers - Validates LFS pointer files for correctness.