- Home /
Why is ProjectSettings.asset unexpectedly modified?
We are using Unity 4 with Git for version control. We have noticed that sometimes when we save a scene, ProjectSettings/ProjectSettings.asset is modified unexpectedly. We are not actually changing any project settings, just saving a scene that has been modified. This behavior introduces potential merge conflicts in Git because this one file is modified even when team members are working on different scenes. We often have to checkout ProjectSettings.asset from our local repositories in order undo the changes and avoid the merge conflict.
Has anyone else experienced this behavior? Is this behavior expected? Is it a bug? Should we be including ProjectSettings in version control? It seems that important information is stored in some of the .asset files in this directory.
Thanks for any help.
Answer by lh · Jun 25, 2013 at 05:01 AM
If everyone's using the same Unity version with the same settings (and those settings files are committed), the modification should stop once the newest version is committed. If you're using Unity 4, you can turn on asset serialization=text and look at what's changing each time. This will also reduce conflicts, in case the changes are actually necessary.
Answer by NoTuxNoBux · Feb 25, 2021 at 06:33 PM
Sorry for bumping an old thread, but this still appears to be an issue in at least Unity 2019.4.18f1. I'm the only person working on the project, the Unity versions has never changed, and I have it set to text serialization, but this file is still modified every so often.
What appears to be modified each time are the preloadedAssets, they keep changing from an empty array:
preloadedAssets: []
... to an array of two items:
preloadedAssets:
- {fileID: 3544322769410698091, guid: 3a92a09800e95b44b9c6c6aae3faaa72, type: 2}
- {fileID: 8985140560771674467, guid: dc0cc7f0011ee6f439796b63cd5ea446, type: 2}
... and back again later on. It could be that this happens during UWP IL2CPP builds, but I'm not sure yet.
Your answer
Follow this Question
Related Questions
.gitignore not ignoring Library. What's the correct way to do it? 1 Answer
Unity Version Control - missing scene files and materials when downloading or cloning. 0 Answers
Unity taking a SEVERAL OF MINUTES importing .ma and .mb files 0 Answers
Git and Unity not working correctly: missing components, textures, materials, etc. 2 Answers
Git Version Control Merging 1 Answer