#1418 Unpack RPMs using rpm2archive
Merged 3 years ago by lsedlar. Opened 3 years ago by lsedlar.
lsedlar/pungi unpack-zstd  into  master

file modified
+2 -1
@@ -189,8 +189,9 @@ 

      """Explode a rpm package into target_dir."""

      pkg_path = os.path.abspath(pkg_path)

      makedirs(target_dir)

+     # rpm2archive writes to stdout only if reading from stdin, thus the redirect

      run(

-         "rpm2cpio %s | cpio -iuvmd && chmod -R a+rX ." % shlex_quote(pkg_path),

+         "rpm2archive - <%s | tar xfz - && chmod -R a+rX ." % shlex_quote(pkg_path),

          workdir=target_dir,

      )

  

This should support both older files compressed with cpio as well as newer zstd-compressed files.

rebased onto 3ff16c8e6e86c057cad5c86610c9e36aea7191f4

3 years ago

The command works for me.

rebased onto cd0dcf2f08ee3e306d1835ab6e3e287be68fab47

3 years ago

rebased onto f5e3395

3 years ago

Pull-Request has been merged by lsedlar

3 years ago