How do I create a bot in Xcode? Getting "Creating a bot requires a project that is under source control."
Asked Answered
Y

6

7

I'm trying to get Continuous Integration setup in Mavericks using OS X Server for Mavericks.

I have the Server installed and my source code is in a local directory using Git from assembla. I'm following the Apple Xcode Continuous Integration Guide, and I'm at the part where I'm adding a bot to the product in Xcode.

I'm getting the error:

Creating a bot requires a project that is under source control. This project appears to be in a local git repository. To be able to create a bot, the project must be in an repository the server can access so it can clone it. [cancel] [Configure Remotes...]

Clicking either cancel or configure remotes brings up the configure for my folder and I see my remote added just fine. I also tried adding the remote repository again with a different name.

How do I move forward?

Yajairayajurveda answered 28/10, 2013 at 6:39 Comment(0)
C
3

It seems like this issue happens when there isn't a remote named "origin", as that's what Xcode is looking for. When I renamed my remote to origin (in <ProjectRoot>/.git/config), Xcode stopped complaining and let me add a bot through the Xcode UI.

Clammy answered 3/1, 2014 at 23:36 Comment(1)
How do I do that?Terwilliger
Y
3

This is hacky, but worked.

In Xcode I clicked the Source Control menu then checkout. I checked out my repository to a new folder and I was able to create my bot.

It seems adding the repository from the command line caused things to not look correctly configured to Xcode.

Yajairayajurveda answered 28/10, 2013 at 6:50 Comment(0)
C
3

It seems like this issue happens when there isn't a remote named "origin", as that's what Xcode is looking for. When I renamed my remote to origin (in <ProjectRoot>/.git/config), Xcode stopped complaining and let me add a bot through the Xcode UI.

Clammy answered 3/1, 2014 at 23:36 Comment(1)
How do I do that?Terwilliger
B
2

After numerous trials I did the following steps to get the whole process to work:

  1. Connect a device to the server. Make sure it is active.
  2. Set up the server and ensure that the XCode service is active.
  3. Create a new project with a local GIT.
  4. In the Source Control menu, select Configure, and under Remotes select to Create New Remote.
  5. Go to Manage Schemes and check the Shared check box.
  6. Commit the project and select Push to master.
  7. Go to the developer site and create an developer and Ad-Hoc profile.
  8. Go to the Xcode settings and reload the profiles for the team / developer.
  9. Configure this profile in the app build settings.
  10. Select to create a bot with CI to run on commit.

The next time you commit this should run the bot etc.

Boycie answered 4/11, 2013 at 0:36 Comment(0)
R
1

I had the same issue when I tried to edit a bot that I created before. In my case the problem was that I created the bot for the master branch, but when I tried to edit it, I had checked out a different branch. After switching back to master I was able to successfully edit my bots.

Recreation answered 3/2, 2015 at 9:58 Comment(0)
P
1

Tried most of the things here. None worked for me. Got this error

Creating a bot requires a project that is under source control..

But when I proceeded with the popup it said

All projects are in workspace (something similar).

I did the below

  • Removed .git folder
  • git init
  • git remote add origin <repo.git>
  • git pull origin <branch_name>
  • removed the conflicting folders and files
  • git pull origin <branch_name>

Then when I clicked create bot from Products it worked.

Procarp answered 23/10, 2020 at 12:2 Comment(0)
F
0

I think I had the easiest time of all. I simply did an Xcode-based commit and push, then tried the bot again, and the nasty error was gone.

[In Xcode 6.4, this would crash the Xcode].

Figment answered 14/8, 2015 at 12:41 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.