Swift: unzipping file
问题 I’m trying to get String from txt file inside the zip file using native libcompression library. Actually I use the code from https://github.com/mw99/DataCompression/blob/master/Sources/DataCompression.swift. At first, I was doing: let zip = try? Data(contentsOf: "/.../test.zip") let tmp: Data? = zip?.unzip() let txt: String? = String(data: tmp!, encoding: .utf8) But how do I get the contents of zip file and how do I get data from certain txt file? 回答1: ZIP Foundation supports accessing