Integrate Projects in a single project

I have same xcode project on two deferent macbooks with different code.we need to merge that code but we are not using any git account.We need to merge same file as well,I mean we have same viewcontroller and added two people add a code in single view controller How i can merge it.
For example:

I have a view controller Name “XYZ”and Person 1 added “Login Method”
into “XYZ” and person 2 added “Sign up Method” into XYZ. and both code
are on deferent macbook without any git account how I can merge

  • git error when trying to push to remote branch
  • How to write or package a Git server as a Java Servlet or Java webapp?
  • Why is putting git repositories inside of a Dropbox folder not recommended?
  • Share a working tree with git submodules
  • using Notepad++ for git inside cygwin
  • Revert to a commit by a SHA hash in Git?
  • How to prevent Gitlab from creating extra merge commit on branch merge
  • git rebase for migrating several commits?
  • Git clone fsync input/output error in linux
  • .gitignore not ignoring node_modules
  • Merging XML file changes in git
  • How to remove emojis from my Github commits?
  • 2 Solutions collect form web for “Integrate Projects in a single project”

    Since you use the git tag, I will provide the way to do version control by git.
    First, please sign up account for bitbucket (free for private repository) or github (only free for public repository). And create a repository. They are as the remote git repository(repo).

    Then use git bash for local repository.

    In one macbook, use these steps:

    1. git clone <URL for your bitbucket or github repo>
    2. cd reponame
    3. copy your xcode project in reponame folder
    4. git add .
    5. git commit -am 'code version from first macbook'
    6. git push

    Now the code in the first macbook is pushed in your remote repo.

    In the other macbook, use these steps:

    1. In an empty folder, use git init
    2. copy your xcode project in this folder
    3. git add .
    4. git commit -am 'code version from second macbook'
    5. git remote add origin <URL for your bitbucket or github repo>
    6. git pull origin master
    7. Now the code from macbook1 is merging in macbook2
    8. If there has conflict files, you should check and save them, and then use git add . and git commit -m 'solve merge conflict'.
    9. Now this is the version that you merge the different macbooks together. You can push the version in remote repo by git push.

    More git related, you can refer git book.

    Any version control system comes to handy in this kind of situations. Merging manually is the option available other than version control system. Either merge using version control system like git or manually merge the files which is very hard to workout.

    Git Baby is a git and github fan, let's start git clone.