How to prevent bunch of .meta, .json file changes from filling up GIT?

How can I prevent Cocos Creator from changing files unnecessarily when I open a freshly cloned project from a GIT repository?

I created a new project and selected helloworld-typescript sample project as the start and run it. Afterwards I committed and pushed everything that wasn’t ignored by the .gitignore file that the engine generated by itself.

The problem is that if I delete the local repository, clone the project again and run it, bunch of changes in GIT will appear - various .meta files and a few .json files. Is there a way to prevent this? I could try ignoring all the .meta files but I’m concerned that they may contain some important data.

Example of files that were marked as modified after running a project cloned from a GIT repository:

modified:   assets/Scene.meta
modified:   assets/Scene/helloworld.fire.meta
modified:   assets/Script.meta
modified:   assets/Script/Helloworld.ts.meta
modified:   assets/Texture.meta
modified:   assets/Texture/HelloWorld.png.meta
modified:   assets/Texture/singleColor.png.meta
modified:   project.json
modified:   settings/project.json
modified:   settings/services.json

did you commit/push your .gitignore back to your repo?

Found a solution to the problem. It has to do with something regarding GIT automatically converting something regarding line endings.

Run the following command:

git config core.autocrlf false

And everything was fine afterwards.

Yup.‎‎‎‎‎‎

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.