Drewsif / PiShrink

Make your pi images smaller!
MIT License
3.47k stars 642 forks source link

shrinkPi for Sonoma #278

Closed ruediheimlicher closed 4 months ago

ruediheimlicher commented 5 months ago

Hi I wanted to use PiShrink on my MBP with macos sonoma I got an error: install -d /usr/local/bin install -m 755 e2fsck /usr/local/bin install -m 755 resize2fs /usr/local/bin install: resize2fs: No such file or directory

Are you planning an update to use under Macos Sonoma? This would be very helpful. Regards Ruedi Heimlicher

monsieurborges commented 5 months ago

Hey @ruediheimlicher you can use PiShrink dockerized | Docker Hub PiShrink:

  1. Install Docker Desktop on Mac

  2. Make a copy of a Raspberry Pi SD card that you want to shrink (see instructions here).

  3. Using the Terminal, access the directory containing the Raspberry Pi image:

cd ~/Directory-with-RPi-image
  1. Run PiShrink dockerized:
docker run --privileged=true --rm \
    --volume $(pwd):/workdir \
    borgesnotes/pishrink \
    pishrink -Zv IMAGE_NAME.img NEW-IMAGE_NAME.img
Drewsif commented 4 months ago

There is currently no official support for MacOS, nor will there be in the future as I can't test it. Follow @borgesnotes docker instructions and that should work for you.