Commit to git after switching to workspace and adding CocoaPods in Xcode?

后端 未结 1 758
南方客
南方客 2021-02-07 01:43

I\'ve just added CocoaPods to my current project in Xcode 5. Of course, CocoaPods created a workspace and I\'ve launched the workspace in Xcode. I see both my project and the Po

1条回答
  •  名媛妹妹
    2021-02-07 02:24

    git add .

    From the directory enclosing your Xcode project, simply execute a git add .. Documentation here.

    Explanation

    You likely had the following hierarchy prior pod init:

    In all likelihood, your git setup starts at the directory enclosing .xcodeproj.

    After pod install, the hierarchy did not change. You merely have more files at the same level:

    The .xcworkspace is next to .xcodeproj, not above. You are free to execute

    git add .
    

    ...followed by

    git commit -m "message"
    

    ...assuming that .gitignore is set up properly, and wether or not you prefer to commit the Pods directory.

    0 讨论(0)
提交回复
热议问题