Why cannot I load .obj file to my repository?

情到浓时终转凉″ 提交于 2019-12-11 03:50:06

问题


I started using github newly. I'm having trouble to load my .obj file to my repository. I found a gitignore file good to use with unity projects and I'm using it.

Temp/
Obj/
UnityGenerated/
Library/

*.svd
*.userprefs
*.csproj
*.pidb
*.sln
*.suo
*.user
*.unityproj
*.booproj

which one of this causes this? or is there any other reason?


回答1:


Your own gitignore is not the culprit here. So something else is likely causing your .obj files to be ignored.

The reason is that .obj files in your context are meshes, but they are also a file format for files which are the result of code compilation.

Several Git clients I know of are trying to help you out by providing you with a global ignore file for Git. So the likely culprit is that such a file (probably located in your home directory) contains an entry causing it to ignore .obj file. Locate the ignore file and adapt it as necessary.




回答2:


The problem is that your repository provider such as "Sourcetree" creates an additional .gitignore file, it's named gitignore_global.txt.

In Windows it's installed by default at C/Users/Documents/gitignore_global.txt. Just open the file and erase the line where it says *.obj.




回答3:


Obj/ will block the whole object directory. I'm guessing it's under there. The *.something ones will block by file ending, which doesn't seem to be the problem.



来源:https://stackoverflow.com/questions/32354561/why-cannot-i-load-obj-file-to-my-repository

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!