Skip to main content

parse_checksum

Function parse_checksum 

Source
fn parse_checksum(content: &str, filename: &str) -> Result<String>
Expand description

Parse a checksums file content and find the hash for filename.

Handles two formats:

  1. Multi-line: <hex_hash> <filename> (with one or two spaces)
  2. Single-line: just a hex hash (for per-file .sha256 files)

ยงErrors

  • No matching entry found for filename.