Should we commit pod files to version control system (GIT or SVN)

后端 未结 3 677
野的像风
野的像风 2021-01-31 15:36

So far I was working on an app and my Team Lead said not to commit the pod files and I just followed his instructions.

Then our Lead changed and he said to commit the p

3条回答
  •  北荒
    北荒 (楼主)
    2021-01-31 16:12

    I suggest & recommend, not to commit pods directory(third party source integrated using Pod) in your Git/SVN repository.

    Here is sample source, suggesting you, what to commit and not.

    1. Pod is a dependency manager and may have so many third party libraries in it. You project source will become heavier (large in size) and the same will get it downloaded every time a new destination uses it.
    2. You can easily integrate all Pod libraries/files source using command pod install from any source/destination.
    3. There may be different version of SDK, command line tool and cocoa pod in different systems. It automatically handles integration specific libraries supported by SDK tool & command line version, as well as cocoa pod version.

    Note: It is not bad, you commit pod files with source code to Git/SVN. But also, that's not good to add dependencies (of third party library) with your code, which is not required and easy to handle using pod on different destinations (systems).


    Update: .xconfig files are not required to commit. PodFile is enough and required to commit.

提交回复
热议问题