Hi Mingye, On Mon, Jul 14, 2025 at 12:55:06AM +0800, Mingye Wang wrote: > Hi all, > > >Gao Xiang Thu, 09 Jan 2025 01:36:16 -0800 > >On 2025/1/9 02:14, Daniel Erez wrote: > >>Would it be applicable to introduce an option for extracting a specific file > >>from the image? > >>I.e. something similar to the '-extract-file' option available in > >>unsquashfs tool [2]. > >I will add this later. > > I am seeing a need for a similar feature in making dracut's lsinitrd > work... a little better. I should add two cents of my own.
dump.erofs already supports `--cat` command to dump a single file. > > * In "unsquashfs" there's not only '-extract-file' for passing in a > list of files, but also a possibility for a list of paths to be > specified directly as arguments. This would appear outlandish on an > fsck utility. Can those be replaced as dump.erofs --cat? > * When extracting single files it might be desirable to *not* verify > and pretend-extract the other files. `fsck.erofs` can be used to dump a subtree in the future (exclude file pattern can be applied), fsck/dump/mkfs tools are more common for generic filesystems. Mimick Squashfs-specific is not EROFS will do since I do see `un`-prefix is common and lack of (even defacto) standardization. Thanks, Gao Xiang