return info
-def parse_table(v: Verification, info: Info) -> None:
+def parse_channel(v: Verification, info: Info) -> None:
v.status('Parsing channel description as XML')
d = xml.dom.minidom.parseString(info.channel_html)
v.ok()
info.table['git-revision'].file).read(999) == info.git_commit)
-def extract_channel(v: Verification, info: Info) -> None:
+def check_channel_contents(v: Verification, info: Info) -> None:
with tempfile.TemporaryDirectory() as d:
v.status('Extracting %s' % info.table['nixexprs.tar.xz'].file)
shutil.unpack_archive(info.table['nixexprs.tar.xz'].file, d)
def main() -> None:
v = Verification()
info = fetch(v, 'https://channels.nixos.org/nixos-20.03')
- parse_table(v, info)
+ parse_channel(v, info)
fetch_resources(v, info)
- extract_channel(v, info)
+ check_channel_contents(v, info)
print(info)