diff options
author | yangchenguang <yangchenguang@uniontech.com> | 2022-10-25 16:57:44 +0800 |
---|---|---|
committer | Panu Matilainen <pmatilai@redhat.com> | 2022-11-23 10:12:38 +0200 |
commit | 37b963fa51d6ad31086a6e345ce6701afda5afff (patch) | |
tree | 6a9afe016345f1fac24df061937c973e67289317 /docs/man | |
parent | 425e2e02963eb2be8c685c75c37e7cc32103326c (diff) | |
download | rpm-37b963fa51d6ad31086a6e345ce6701afda5afff.tar.gz |
Allow piping from rpm2archive
If stdout is not a terminal, output the archive(s) to it, instead of
creating file(s) on disk. This makes rpm2archive consistent with
rpm2cpio.
Based on a patch from yangchenguang <yangchenguang@uniontech.com>.
Fixes: #2208
Diffstat (limited to 'docs/man')
-rw-r--r-- | docs/man/rpm2archive.8.md | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/docs/man/rpm2archive.8.md b/docs/man/rpm2archive.8.md index cd037be5c..1b6c56ccb 100644 --- a/docs/man/rpm2archive.8.md +++ b/docs/man/rpm2archive.8.md @@ -17,12 +17,13 @@ SYNOPSIS DESCRIPTION =========== -**rpm2archive** converts the .rpm files specified as arguments to tar -files. By default they are gzip compressed and saved with postfix -\".tgz\". +**rpm2archive** converts the .rpm files specified as arguments to tar archives +on standard out. -If \'-\' is given as argument, an rpm stream is read from standard in -and written to standard out. +If a \'-\' argument is given, an rpm stream is read from standard in. + +If standard out is connected to a terminal, the output is written to tar files +with a \".tgz\" suffix, gzip compressed by default. In opposite to **rpm2cpio** **rpm2archive** also works with RPM packages containing files greater than 4GB which are not supported by cpio. @@ -41,8 +42,8 @@ EXAMPLES ======== \ -***rpm2archive glint-1.0-1.i386.rpm ; tar -xvz -glint-1.0-1.i386.rpm.tgz***\ +***rpm2archive glint-1.0-1.i386.rpm \| tar -xvz***\ +***rpm2archive glint-1.0-1.i386.rpm ; tar -xvz glint-1.0-1.i386.rpm.tgz***\ ***cat glint-1.0-1.i386.rpm \| rpm2archive - \| tar -tvz*** SEE ALSO |