iosxcodecocoapodsbitbucketxcode-workspace

Push Workspace with multiple projects on Bitbucket repository


I have Xcode workspace which has multiple projects - the main project and a pod project. How do I push the code (the first time) on Bitbucket so that everything is set on repository ? Attached is the project structure just for clarification

enter image description here

This is the folder structure I have

enter image description here


Solution

  • All you got to do is go to the Project folder in Terminal and follow the below commands in the same order. I am assuming both your main project and pod project are inside the same folder

    So in terminal go inside your first AppIT folder. If you run command ls -l in terminal on that folder you will see a list of all folders and files inside it like AppIt, .xcodeProj file, Pod folder, Podfile etc. Just run the below commands on that location where you see this list.

    git init
    git add -A .
    git commit -m "first commit"
    git remote add origin https://github.com/.... .git // your complete URL
    git push -u origin master