mrkkrp / zip

Efficient library for manipulating zip archives
Other
81 stars 27 forks source link

Zstandard compression method support #70

Closed csabahruska closed 4 years ago

csabahruska commented 4 years ago

Hi,

The official .zip format now supports the fast and efficient Zstandard (zstd) compression method. https://en.wikipedia.org/wiki/Zip_(file_format)#Version_history Could you add support for it? https://hackage.haskell.org/package/conduit-zstd

mrkkrp commented 4 years ago

I'd accept a PR adding support for it.

csabahruska commented 4 years ago

Ok :)

csabahruska commented 4 years ago

I've made the changes that I thought were necessary but it only works with an older zip version number. The test are failing with zip specification version [6, 3, 8] and the tests are passing with [4, 6] My patch: https://github.com/csabahruska/zip/commit/c3d7a0c340d9af1cb884e4d946d949c122fdc777

the problematic part:

      Just Zstd -> [4, 6] -- FIXME: [6, 3, 8]

Do you have any idea why is that? (My guess that it is related to zip64)

mrkkrp commented 4 years ago

Can you open a PR? I'll take a look.

csabahruska commented 4 years ago

Problem is fixed in https://github.com/csabahruska/zip/commit/04cb4f903f3c6956ba8b0643026899a03c6832c6, everything is fine. Also opened a PR. https://github.com/mrkkrp/zip/pull/71