debian_inspector.contents module
- debian_inspector.contents.parse_contents(location, has_header=True)
Return a mapping of {path: [list of packages]} and a mapping of {package: [list of paths]} from parsing a Debian Contents file at
location
. The Contents file are typically gzipped but we also accept plain text files.If
has_header
is True, the file is expected to have a header narrative and a FILE/LOCATION columns headers before the table starts in earnest.See https://wiki.debian.org/DebianRepository/Format#A.22Contents.22_indices for format details.