• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1zip-rs
2======
3
4[![Build Status](https://img.shields.io/github/workflow/status/zip-rs/zip/CI)](https://github.com/zip-rs/zip/actions?query=branch%3Amaster+workflow%3ACI)
5[![Crates.io version](https://img.shields.io/crates/v/zip.svg)](https://crates.io/crates/zip)
6[![Discord](https://badgen.net/badge/icon/discord?icon=discord&label)](https://discord.gg/rQ7H9cSsF4)
7
8[Documentation](https://docs.rs/zip/0.6.2/zip/)
9
10> PSA: This version of the ZIP crate will not gain any new features,
11>      and will only be updated if major security issues are found.
12
13Info
14----
15
16
17A zip library for rust which supports reading and writing of simple ZIP files.
18
19Supported compression formats:
20
21* stored (i.e. none)
22* deflate
23* bzip2
24* zstd
25
26Currently unsupported zip extensions:
27
28* Encryption
29* Multi-disk
30
31Usage
32-----
33
34With all default features:
35
36```toml
37[dependencies]
38zip = "0.6.2"
39```
40
41Without the default features:
42
43```toml
44[dependencies]
45zip = { version = "0.6.2", default-features = false }
46```
47
48The features available are:
49
50* `aes-crypto`: Enables decryption of files which were encrypted with AES. Supports AE-1 and AE-2 methods.
51* `deflate`: Enables the deflate compression algorithm, which is the default for zip files.
52* `bzip2`: Enables the BZip2 compression algorithm.
53* `time`: Enables features using the [time](https://github.com/rust-lang-deprecated/time) crate.
54* `zstd`: Enables the Zstandard compression algorithm.
55
56All of these are enabled by default.
57
58MSRV
59----
60
61Our current Minimum Supported Rust Version is **1.54.0**. When adding features,
62we will follow these guidelines:
63
64- We will always support the latest four minor Rust versions. This gives you a 6
65  month window to upgrade your compiler.
66- Any change to the MSRV will be accompanied with a **minor** version bump
67   - While the crate is pre-1.0, this will be a change to the PATCH version.
68
69Examples
70--------
71
72See the [examples directory](examples) for:
73   * How to write a file to a zip.
74   * How to write a directory of files to a zip (using [walkdir](https://github.com/BurntSushi/walkdir)).
75   * How to extract a zip file.
76   * How to extract a single file from a zip.
77   * How to read a zip from the standard input.
78