diff --git a/tar.md b/tar.md index f2894cd09cb..b632fbd8caa 100644 --- a/tar.md +++ b/tar.md @@ -34,6 +34,11 @@ tar -xzf archive.tar.gz -C /target/directory tar -zu archive.tar.gz -C /target/file ``` +```shell +# List the contents of an archive +tar -tf archive.tar.gz +``` + ### Common options | Option | Description | @@ -44,3 +49,4 @@ tar -zu archive.tar.gz -C /target/file | `f` | filename of the archive | | `v` | verbose, display what is inflated or deflated | | `a` | unlike of `z`, determine compression based on file extension | +| `t` | list the contents of an archive