find_xmls

Function find_xmls 

Source
pub fn find_xmls(path: &Path) -> AppResult<Vec<(String, Vec<PathBuf>)>>
Expand description

Finds all XML/Atom files organized by subdirectory.

This function scans the immediate subdirectories of the given path and recursively collects all .xml and .atom files within each subdirectory. Files in the top-level directory are ignored.

§Returns

Returns a vector of tuples where:

  • First element: Subdirectory name (e.g., “202301”)
  • Second element: Vector of paths to XML/Atom files found in that subdirectory

Only subdirectories containing at least one XML/Atom file are included.

§Arguments

  • path - Base directory to search (typically the extraction directory)

§Errors

Returns an error if directory reading fails.