Update cheatsheets

This commit is contained in:
ivuorinen
2024-02-21 11:19:49 +00:00
parent 4e88a1b42f
commit 3d653cc7e6
4803 changed files with 127002 additions and 0 deletions

41
7z Normal file
View File

@@ -0,0 +1,41 @@
---
syntax: markdown
tags: [tldr, common]
source: https://github.com/tldr-pages/tldr.git
---
# 7z
> File archiver with a high compression ratio.
> More information: <https://manned.org/7z>.
- [a]dd a file or directory to a new or existing archive:
`7z a {{path/to/archive.7z}} {{path/to/file_or_directory}}`
- Encrypt an existing archive (including filenames):
`7z a {{path/to/encrypted.7z}} -p{{password}} -mhe=on {{path/to/archive.7z}}`
- E[x]tract an archive preserving the original directory structure:
`7z x {{path/to/archive.7z}}`
- E[x]tract an archive to a specific directory:
`7z x {{path/to/archive.7z}} -o{{path/to/output}}`
- E[x]tract an archive to `stdout`:
`7z x {{path/to/archive.7z}} -so`
- [a]rchive using a specific archive type:
`7z a -t{{7z|bzip2|gzip|lzip|tar|zip}} {{path/to/archive}} {{path/to/file_or_directory}}`
- [l]ist the contents of an archive:
`7z l {{path/to/archive.7z}}`
- Set the level of compression (higher means more compression, but slower):
`7z a {{path/to/archive.7z}} -mx={{0|1|3|5|7|9}} {{path/to/file_or_directory}}`