#[non_exhaustive]pub struct FsSourceConfig {
pub paths: Vec<PathBuf>,
pub exclude: Vec<String>,
pub max_file_size: u64,
pub follow_links: bool,
pub max_depth: usize,
pub max_files: usize,
pub max_total_bytes: u64,
}Expand description
Filesystem-specific source options.
NOTE: paths is required and must be non-empty. Default scan roots
(e.g. docs/modules/libs/examples) are a CLI/wrapper concern, not
baked into the library — keeps gts-validator repo-layout-agnostic.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.paths: Vec<PathBuf>Paths to scan (files or directories). Required, must be non-empty.
exclude: Vec<String>Exclude patterns (glob format).
max_file_size: u64Maximum file size in bytes (default: 10 MB).
follow_links: boolWhether to follow symbolic links.
Defaults to false — following symlinks allows escaping the repository
root, traversing system directories, and reading secrets in CI environments.
Only enable if you explicitly trust all symlinks in the repository.
max_depth: usizeMaximum directory traversal depth (default: 64). Prevents infinite recursion via deeply nested symlinks or directories.
max_files: usizeMaximum total number of files to scan (default: 100_000).
Prevents memory exhaustion on pathological repositories.
max_total_bytes: u64Maximum total bytes to read across all files (default: 512 MB). Prevents memory exhaustion when many large files are present.
Trait Implementations§
Source§impl Clone for FsSourceConfig
impl Clone for FsSourceConfig
Source§fn clone(&self) -> FsSourceConfig
fn clone(&self) -> FsSourceConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more