On Fri, Dec 15, 2023 at 09:15:22AM +0100, lacsaP Patatetom wrote:
> here's a little script following the exchanges above.
> perhaps it will be useful to others...

If you want a full disk image with its partition table I don't know if
you are aware that those tools can work with offsets, e.g.:

  $ truncate -s 500M disk.img
  $ echo -e 'label:gpt\n2048,,U' | sfdisk disk.img
  $ mkfs.fat --offset 2048 disk.img 
  $ mcopy -i disk.img@@1M -s /path/to/files ::

where 2048 is the offset of the first partition (2048 sectors = 1MB)

Berto

Reply via email to