Git ignore file for Xcode projects

后端 未结 20 1192
栀梦
栀梦 2020-11-22 03:03

Which files should I include in .gitignore when using Git in conjunction with Xcode?

20条回答
  •  渐次进展
    2020-11-22 03:35

    Regarding the 'build' directory exclusion -

    If you place your build files in a different directory from your source, as I do, you don't have the folder in the tree to worry about.

    This also makes life simpler for sharing your code, preventing bloated backups, and even when you have dependencies to other Xcode projects (while require the builds to be in the same directory as each other)

    You can grab an up-to-date copy from the Github gist https://gist.github.com/708713

    My current .gitignore file is

    # Mac OS X
    *.DS_Store
    
    # Xcode
    *.pbxuser
    *.mode1v3
    *.mode2v3
    *.perspectivev3
    *.xcuserstate
    project.xcworkspace/
    xcuserdata/
    
    # Generated files
    *.o
    *.pyc
    
    
    #Python modules
    MANIFEST
    dist/
    build/
    
    # Backup files
    *~.nib
    

提交回复
热议问题