【发布时间】:2010-07-15 18:24:18
【问题描述】:
我开始在一个 xcode 项目中使用 git,最近发现我可以使用 .gitignore 和 .gitattributes 文件来忽略来自编译器和系统的噪音。 现在我已经有了 .gitignore 和 .gitattributes 文件,我该如何“应用”新的忽略规则并摆脱版本控制中的垃圾?
我的 .gitignore 文件是:
# xcode noise
*.modelv3
*.pbxuser
*.perspective
*.perspectivev3
*.pyc
*~.nib/
build/*
# Textmate - if you build your xcode projects with it
*.tm_build_errors
# old skool
.svn
# osx noise
.DS_Store
profile
我的 .gitattributes 文件是:
*.pbxproj -crlf -diff -merge
谢谢!
【问题讨论】:
-
+1 Chris 评论中的链接对我来说比此页面上的任何内容都更有效。
-
不,不, this is the right way。大多数建议的答案重新提交所有文件。
标签: git