Reclaiming Disk Space From Xcode
If you are an iOS developer, execute this:
$ xcrun simctl delete unavailableIt removes old simulators Xcode no longer use. For me it was 6Gb
[…]
You can also delete ~/Library/Developer/Xcode/Device Support If you want to gain back more space.
Xcode will regenerate what’s needed
Be careful; if you switch Xcode versions then Simulators for “other” versions of iOS can show as unavailable.
my “freespace” alias:
sudo rm -rf /.DocumentRevisions-V100/ rm -rf ~/Library/Developer/Xcode/DerivedData rm -rf ~/Library/Developer/Xcode/Archives rm -rf ~/Library/Developer/Xcode/iOS\ DeviceSupport rm -rf ~/Library/Caches/com.apple.dt.Xcode xcrun simctl delete unavailable
I guess you ran out of characters, but don’t forget to also nuke watchOS DeviceSupport and tvOS DeviceSupport
3 Comments RSS · Twitter
Wow. I've got a 2013 MacBook Air with a 256Gig drive that always seems to be within 20 or 30 Gigs of being full. Every few weeks I have to spend an hour or so laboriously looking for stuff to delete. I tried Fabio's recommended script above and recovered how much space you ask? Hard to believe, but I just freed up 100 Gig. Holy shit, Batman! I'm a very happy camper. :-)
[…] Bei Recherche finde ich dieses Link (es gibt natürlich mehrere): https://mjtsai.com/blog/2019/03/29/reclaiming-disk-space-from-xcode/. […]