gunzipとは、GZIP形式で圧縮されたファイルを解凍するUnix/Linuxコマンドであり、GNUプロジェクトによって開発されている。なお、GZIP形式はZIP形式と互換性が無い。
gunzip [-acfhklLnNrtvV] [-S suffix] [name]...
$ gunzip example.gz
拡張子が .gz の場合は、拡張子の指定を省略できる。
$ gunzip example
展開(解凍)するファイルは複数指定できる。
$ gunzip foo.gz bar.gz baz.gz
以下に示すオプションを gunzip コマンドに指定できる。
| OS | 改行コード | 表記 |
|---|---|---|
| Linux / Unix | LF | \n |
| macOS | LF | \n |
| Microsoft Windows | CR + LF | \r\n |
$ gzip -h
$ gzip --help
$ gunzip -L
$ gunzip --license
$ gunzip -q example.tar.gz
$ gunzip --quiet example.tar.gz
$ gunzip -v example.tar.gz
$ gunzip --verbose example.tar.gz
$ gunzip -V
$ gunzip --version
Internet Engineering Task Force, "RFC 1952 (GZIP file format specification version 4.3)", 1996.