最近mbp空间越来越小, 看了一下替换mbp硬盘贵的要死, 还是清理一下mac里面无用的内容吧
0.这里我推荐大家使用OmniDiskSwipper, 它可以列出硬盘里面哪里有占资源的文件和文件夹, 通过这个和底下stackoverflow的删除建议, 配合使用可让你的mac腾出不少可用空间, 中文并非直译, 结合自己删除的总结.
转自:https://stackoverflow.com/questions/29930198/can-i-delete-data-from-ios-devicesupport
1.模拟器运行数据目录, 可几天一删
~/Library/Developer/Xcode/DerivedData
DeviceSupport - You can keep the simulator which log's you may need in future. It's actually symbolicate crash logs for different device/iOS.
Delete this folder after every few days interval
2.打包文件都在这里, 如果打包文件发布, 并且不再接受苹果反馈(玩家崩溃的log会下载下来用这个来解析), 就可以删掉
~/Library/Developer/Xcode/Archives
All your targets are kept in archived form in Archives folder. Before you decide to delete contents of this folder, here is a warning - if you want to be able to debug deployed versions of your App, you shouldn’t delete the archives
3.当你连接设备时, 会拷贝设备的simbols到本目录, 手上设备如果没有的版本可以删掉
~/Library/Developer/Xcode/iOS DeviceSupport
iOS Device Support folder creates a subfolder with the device version as identifier when you attach the device. Most of the time it’s just old stuff. Keep the latest version and rest of them can be deleted (if you don’t have an app that runs on 5.1.1, there’s no reason to keep the 5.1.1 directory/directories).
4.模拟器目录, 可以删掉不需要的, 不过最好在xcode的Organizer下删除不必要的, 比较明了
~/Library/Developer/CoreSimulator
Core Simulator folder is familiar for many Xcode users. It’s simulator’s territory; thats where it stores app data. It’s obvious that you can toss the older version simulator folder/folders if you no longer support your apps for those versions. And, it’s safer to use ‘Reset content and Settings’ option from menu to delete all of your app data in a Simulator.
5.苹果反馈的崩溃的log, 如果你已经修正了log, 就可以都删了
~/Library/Caches/com.apple.dt.Xcode
Caches are always safe to delete since they will be recreated as necessary. This isn’t a directory, it’s a file of kind Xcode Project. Delete away!
6.itunes设备备份, 保留最近一份, 然后其他可清理掉
~/Library/Application Support/MobileSync/Backup
Additionally, Apple iOS device automatically syncs specific files and settings to your Mac every time they are connected to your Mac machine. To be on safer side, it’s wise to use Devices pane of iTunes preferences to delete older backups; you should be retaining your most recent back-ups off course.