From dbda0fc755788320636b756e5677effc9794cf2e Mon Sep 17 00:00:00 2001 From: Emily Grace Seville Date: Sat, 31 Dec 2022 08:51:52 +1000 Subject: [PATCH] unzip: refresh page (#7997) * Refresh unzip page: - more general descrptions - more general examples * Mention `zip` command * Don't use brace expansion * Update pages/common/unzip.md * Use `list` term in the last example * Apply suggestions from code review * Fix command description * Apply suggestions from code review --- pages/common/unzip.md | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/pages/common/unzip.md b/pages/common/unzip.md index f64fa8d68..bdcdb7328 100644 --- a/pages/common/unzip.md +++ b/pages/common/unzip.md @@ -1,24 +1,25 @@ # unzip -> Extract compressed files in a ZIP archive. +> Extract files/directories from ZIP archives. +> See also: `zip`. > More information: . -- Extract zip file(s) (for multiple files, separate file paths by spaces): +- Extract all files/directories from specific archives into the current directory: -`unzip {{file(s)}}` +`unzip {{path/to/archive1.zip path/to/archive2.zip ...}}` -- Extract zip files(s) to given path: +- Extract files/directories from archives to a specific path: -`unzip {{compressed_file(s)}} -d {{path/to/put/extracted_file(s)}}` +`unzip {{path/to/archive1.zip path/to/archive2.zip ...}} -d {{path/to/output}}` -- List the contents of a zip file without extracting: +- Extract files/directories from archives to `stdout`: -`unzip -l {{file.zip}}` +`unzip -c {{path/to/archive1.zip path/to/archive2.zip ...}}` - Extract the contents of the file(s) to `stdout` alongside the extracted file names: -`unzip -c {{file.zip}}` +`unzip -O {{gbk}} {{path/to/archive1.zip path/to/archive2.zip ...}}` -- Extract a zip file created on Windows, containing files with non-ASCII (e.g. Chinese or Japanese characters) filenames: +- List the contents of a specific archive without extracting them: -`unzip -O {{gbk}} {{file.zip}}` +`unzip -l {{path/to/archive.zip}}`