-->

What should I do about xcuserdata directories with

2020-08-09 10:25发布

问题:

(I have a mac running Mountain Lion with Xcode 4.5.2)

I changed my username a while ago, and Xcode has started recreating xcuserdata directories with the new username at $path_to_.xcodeproj/xcuserdata/blackl.xcuserdatad. I've been working with it like that since, and I can't remember if anything seemed to have reset after the change, so whatever was in there must not have been too important…

What does Xcode store in xcuserdata and what should I do about the old ones? There are some old projects I haven't opened since the change; I could just rename the directories in those. Newer projects will have two directories (blackl.xcuserdatad and one with the old username); what should I do in those cases?

回答1:

You can safely delete the xcuserdata directories. It basically contains personal settings like breakpoints, user interface layout, open files, automatic snapshots configuration and so on.

Most people ignore those files in their version control software. I do that too.

BTW: there's another xcuserdata directory inside of $path_to_.xcodeproj/project.xcworkspace.