.gitignore
--------------------------------------------------------------------------------
.gitignore可以指定哪些文件不纳入版本库的管理
参考网址:https://github.com/github/gitignore
# 命令行中进入与.git同级的目录
$ cd /Users/user/Desktop/project
将以下命令一次性粘贴到命令行中
--------------------------------------------------------------------------------
echo -e "# Xcode
#
build/
*.pbxuser
*.mode1v3
*.mode2v3
*.perspectivev3
xcuserdata
*.xccheckout
*.moved-aside
DerivedData
*.hmap
*.ipa
*.xcuserstate
# CocoaPods
#
# We recommend against adding the Pods directory to your .gitignore. However
# you should judge for yourself, the pros and cons are mentioned at:
# http://guides.cocoapods.org/using/using-cocoapods.html#should-i-ignore-the-pods-directory-in-source-control
#
# Pods/" > .gitignore
--------------------------------------------------------------------------------
# 将.gitignore添加到代码库
$ git add .gitignore
本文介绍了如何为Xcode项目创建.gitignore文件以排除不必要的文件和目录,避免这些文件被纳入版本控制系统。通过具体的命令和示例,展示了如何设置.gitignore来忽略Xcode的构建产物及CocoaPods相关文件。
1207

被折叠的 条评论
为什么被折叠?



