简体   繁体   English

如何阻止XCode生成xcuserdata文件夹和xcuserstate文件?

[英]How to stop XCode from generating xcuserdata folder and xcuserstate files?

XCode automatically generates files in .xcodeproj project file and in .xcworkspace etc... XCode自动生成.xcodeproj项目文件和.xcworkspace等文件...

ProjectFolder.xcodeproj/project.xcworkspace/xcuserdata ProjectFolder.xcodeproj / project.xcworkspace / xcuserdata

this sometimes get's corrupted and make XCode crash upon launching or changing a window inside, how do I make XCode to not memorize window settings when I launch it again? 这有时会被破坏,并且在启动或更改窗口内部时会导致XCode崩溃,当我再次启动时,如何让XCode不记住窗口设置?

note, I locked com.apple.dt.Xcode.savedState folder in 请注意,我锁定了com.apple.dt.Xcode.savedState文件夹

~/Library/Saved Application State/

and it never writes there. 它永远不会写在那里。

EDIT 编辑

I made this simple shell script, and it get's the job done : https://github.com/deya-eldeen/XCodeProjectCleaner 我制作了这个简单的shell脚本,它完成了工作: https//github.com/deya-eldeen/XCodeProjectCleaner

Why not just write a little shell script that deletes the files you want, and then launches Xcode? 为什么不写一个删除所需文件的shell脚本,然后启动Xcode? Instead of opening Xcode, open the script. 而不是打开Xcode,打开脚本。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM