decode index checksum too cus why not

also dumps prettier package descriptions to a file now wahoo
I have good priorities
This commit is contained in:
2024-11-10 17:35:07 +11:00
parent 5e4cf1bbc9
commit 84e8c43c1d
5 changed files with 170 additions and 8 deletions

View File

@ -42,13 +42,10 @@ public struct ApkIndexUpdater {
do {
let tables = try repositories.map { try readIndex(URL(filePath: $0.localName)) }
index = ApkIndex.merge(tables)
try index.description.write(to: URL(fileURLWithPath: "packages.txt"), atomically: false, encoding: .utf8)
} catch {
fatalError(error.localizedDescription)
}
for package in index.packages {
print("\(package.name):", package.dependencies)
}
}
private func readIndex(_ indexURL: URL) throws -> ApkIndex {