New iOS project, free hosted repository: Xcode 4 or Xcode 3.2? - xcode

I wonder whether I should start development of a new iOS project in Xcode 4 or 3.2 - on one hand, I know 3.2 (a little), there is lots of info about it out there, and it's stable and proven. On the other hand, Xcode 4 brings some improvements as well. Are the newer previews of Xcode 4 ready for prime time, or are they still too buggy?
I'm especially interested in issues with (and recommendations of) externally hosted repositories, as I was not very happy with how Xcode 3.2 played with the Subversion repository in my last project.
Which one to choose, and which (preferably free and externally hosted) repository to match?

Today (3rd Feb 2011) Apple released the GM-Seed of xcode4. It's now ready for usage and you can compile your apps and release to the app-store. So if you are new with xcode, I would suggest using xcode4.
Why?
The new compiler has a lot of optimizations done. The compiler (as far as I can see the results) generates faster code. It's big fun!
The new Userinterface is more reliable. It makes your development a lot faster!
2a. Interface builder is now integrated. You can "drag and drop" your userinterface Item using the "ctrl"-key into your code and xcode creates the source for you! This accelerates creation of userinterfaces a lot!
git support has been added to sourcecontrol, which makes development in teams easier
The new LLVM compiler shows errors immediately while coding. And it displays errors, which xcode3 never mentioned
In xcode4 Apple changed a lot! So if you start with xcode3, you will have a new learning curve with xcode 4. For newbs I suggest: Download the xcode4 goldmaster and get startet with xcode4!

I second JackPearse's endorsement of Xcode 4, with one caveat. Been using Xcode 4 for a couple of days and am really starting to like it. Particularly like the way it shows the changes in each file as you commit. Unfortunately, when you delete a file, it forgets that it will need to be deleted in the repository as well. But the big BUT right now is that Xcode 4 will immediately crash the moment you try to do any Core Data modeling. See also XCode 4 Data Model Versioning bug? here on Stack Overflow. So, if you plan to use Core Data, you'll need to keep Xcode 3 around as well until they fix this.

Related

How to migrate/update to newer version of Xamarin.Forms?

I have some xamarin.forms 1.xx( I dont know which version) project on multiple platforms Android and iOS. And I've been asked to upgrade it to the maximum available right now version of xamarin.forms.
Therefore, I have 2 questions:
1) How to determine which version of forms I'm using right now (I'm working in Windows environment using Visual Studio 2015 ).
2) How to migrate/update to newest version of forms? (step by step, if it's possible). I have no idea how the result of that kind of operation supposed to look like, cuz I have never done anything like this before in my life. And what the best practices are?
What I've done is opened VS2015->Help->Xamarin release notes, however there was nothing about version of Forms I'm using. Also, I went to the official xamarin website and there was no guide how to do that. I also tried to look at the release notes the last Forms update and trying to find and fix differences, but my project is so big and I thought that this way doesn't seems right.
I'll answer first the What are the best practice regarding upgrading a Xamarin.Forms application? first and then address your other concerns.
I recently upgraded from 1.5.1 to 2.3.2, and from my experience, this is the steps to go through:
Decide which version you will upgrade from and to.
Read the change logs for all stabled releases between these two versions and look for breaking changes/bugfixes. You can find the release notes on Xamarin's website or on NuGet's website too.
Check regularly for new releases on the Xamarin.Forms forum and check if any reported issues may affect you. Every time Xamarin makes a release, there is a thread full of comments from other developers that may have encountered issues you might be interested in.
Using your favorite versioning software, make sure that all local changes are commited or stashed and create a new branch for your Xamarin.Forms upgrade (you don't know how long the upgrade will take and you still want to be able to send patches during the process)
Upgrade: Read the Important notes at Xamarin.Forms 2.3.2 release notes, especially the When upgrading Xamarin.Forms take care not to simply "update all" as ... part. Remember to upgrade on your PCL project, on your iOS project and on your Android project.
Test your whole app on as many devices as possible and for the longest possible period before you merge your branch back into your development/master/Main branch and address the potential incompatibility issues that may have been created in your development/master/Main simultaneously.
Step 3 is very important as it will allow you to reset back to your starting point and restart if you should fail to upgrade for whatever reason.
Xamarin.Forms is moving fast so it's important that you always keep an eye on what's going on even if you don't upgrade.
Which version am I using right now?
You can check that in the NuGet package interface or in the packages.json file in your project.

Xcode 6.4 crashes in Swift breakpoint

In one project I'm using I can't set breakpoints in Swift code, Xcode always crashes when reaching one of them, doesn't matter if it's a "manual" or an exception breakpoint.
In other projects everything works as expected, only for one project Xcode 6.4 (6E35b) always crashes.
I tried cleaning, deleting derived data, resetting simulator, restarting Xcode/Mac - nothing helped at all.
Anyone else experiencing this problem and hopefully knows what helps?
EDIT
Seems only to be the case on one machine (Xcode 6.4, 10.10.5), but not on the other (Xcode 6.4, El Capitan). But as I mentioned in the comments, reinstalling Xcode didn't help, are there some other preferences I could reset/delete?
EDIT2
Here's the Xcode crash log file:
https://dl.dropboxusercontent.com/u/119600/Xcode_2015-08-12-074655_Stefans-iMac.crash
I would try uninstalling and reinstalling Xcode to see if it helps... I've heard of successes with this technique for similar issues.
Just delete the entire Xcode.app from /Applications, and reinstall from the .dmg. If you're not certain of the binaries and have time / bandwidth, consider re-downloading the .dmg.
If that doesn't work, try the following source control tricks (substitute "your favorite revision control" for "git"):
Try purging all objects not in source code control
Another approach: Check out the app again into a fresh repository (this will get even the files that may have been committed but ignored later).
If not under source code control, grab a .gitignore from here and add it to git, then check out into another directory (this will leave everything but source, interface builder, project files and resources/assets behind).
I'd suggest moving the breakpoint code to another location (such as making a function call and breaking either before or inside the function). However, if all Swift code has this problem, that may not work.
Finally, after making an interim commit (to roll back to), try it in Xcode 7 beta. Bit of a hassle because you have to upgrade to Swift 2.0, but if you keep the deployment target the same no iOS target changes are needed.
If this really is a burden and/or it's a small project, you could try creating a new project and migrating the files and storyboard over, but likely this is too much effort.
Either way, since you note it's pretty much all breakpoints in Swift code, file a bug with Apple's bug reporter. They really need to hear about issues such as this, since you don't seem to be alone in having this issue.
EDIT: Where are others seeing this issue?
Maybe we can see commonality -- since this is only reported in Swift projects (so far). A colleague has seen this problem with breakpoints (as well as stepping through code) in Xcode 6.4 on 10.10.4. (I've seen Xcode 6.4 crashes in the past as well).
I see OS version 10.10.5 mentioned as a target where this happens (#swalkner); is this a beta? If OS 10.10.4/5 is the only place we see this, it might be significant. If it's a project/OS interaction, it might be tricky to reproduce / fix, but I'd encourage everyone to submit detailed bug reports to Apple (maybe even link this post).
Some points to note if you're seeing this:
Operating System Version
Hardware
Target: Simulator vs. Hardware; iOS vs WatchKit app.
Target SDK version(s)
Swift only? Or on an Objective-C only project? Mixed?
Only one project, or several?
It's a longshot, but let me know if it's working:
uncheck the "Always show Dissasembly" check
Debug > Debug Workflow > Always Show Disassembly
In older versions of Xcode (<6.1):
Product > Debug Workflow > Show Disassembly When Debugging
I've just spent the past few hours trying to solve exactly the same issue.
I thought at first, it had started due to installing Xcode 7 on the same machine as Xcode 6.4. The problem certainly coincided.
However, due to having version control, I could look and see what files had changed since opening the project with Xcode 7.
The images.xcassets file had changed. Reverting this file back has stopped Xcode from crashing each time it hit a breakpoint.
I'm not sure whether this helps at all, but definitely look at images.xcassets and if needs be, delete it, recreate it and ensure it's setup 100%. It certainly fixed my issue.

What happens to my project when updating from xCode 5.1 to xCode6?

I'm currently using xCode 5.1 and Objective-C to learn how to make apps and I'm wondering what would happen to my projects if I update from 5.1 to 6. Will my projects still run or will I have to code everything in Swift?
Your projects should still run if they were running in previous versions. What will most likely happen is that you will be bombarded by warnings and alerts about deprecated code and syntax. You're going to get a lot of them with an upgrade that big.
For the most part, XCode should tell you exactly what needs to be upgraded. It shouldn't change any of your code. But it's always good practice to back up your project.
Good luck!
See also : https://stackoverflow.com/a/24005402/4329655

How do I open project version 1.0 with xcode 4.2?

I downloaded this Xcode project(version 1.0 as in contents.xcworkspacedata) from here
When I try to open it, got this error:
Failed to load project at '.../Lesson31_OSXCocoa/Lesson31_OSXCocoa.pbproj', incompatible project version.
How do I open project version 1.0 with xcode 4.2?
You're better off trying to find a newer tutorial, or just studying the code as-is, without expecting to build and run it.
Judging by the modification dates, this code is almost ten years old. Even if you can get a modern version of XCode to open it, there's no reason to think that the headers, libraries, etc., that it needs to compile and run will still be compatible. Moreover, ten years is a long time in software terms. While some of the content might still be applicable, it certainly won't be anywhere near the cutting edge (which itself won't be new by the time you've mastered it).
All that said, if you're really intent on working with that project file in XCode 4.2, the best way is probably to convert it the same way a continuously developed project would have: XCode by XCode.
You can download older versions of XCode from Apple here (requires free Apple developer account).
Some older version will be able to import that file and update it to a newer format.
Assuming you don't stop at that point and use that version of XCode, you can repeat the process with the updated project file and ever-newer versions of XCode until you've arrived at version 4.2.
Relatively easy to make a new project and add the appropriate files to it. Took less than 10 minutes (had to update the code in a few places). Note that I didn't spend much time cleaning up this old code - quite a few deprecated warnings. But it runs and works. I have Xcode 4.3.2 installed but hopefully you'll be able to open it with 4.2. Here's a link to it: Lesson31.zip
Note that the process for doing this (so you can do it for any others), is to create a new Mac OS X Cocoa Application project, add the files (except main.m) from the old project to the new project, and then add necessary libraries to fix link errors (OpenGL Framework). If there's a nib then you can open that in Xcode and copy the window with view and controller out of that project and paste them into the .xib file created with the new project. Then fix compiler warnings/errors as necessary (add a few (char*) coerces, remove reference to std::ios::nocreate which doesn't seem to be available, etc).

Xcode 4.1.1 constantly reindexing after a refactor

Currently splitting an App into a (hopefully) reusable library for other games of the same franchise, and the game specifics, i do a 'lot' of refactoring. It seems that as i advance in this monk work, Xcode is creeping to a stall because it spends more and more time on reindexing the project after each refactoring action.
Any thoughts ?
MBP quadCore 2.3Ghz, 8GB, Lion, xCode 4.1.1
PS. I've had to step out of Xcode because of this, currently doing my refactoring with JetBrains' AppCode ... immature but promising product, but good enough for that work. Beats the pants out of Xcode on many code intensive usages.
It sounds like your project index might be a little messed up. Have you tried deleting the project's Derived Data?
Open the Projects organizer window (Command-Shift-2, click the Projects tab). Select your project and click the Delete button next to the Derived Data path. Xcode will recreate the derived data (it'll index one more time and your next build will be a full build from scratch).
ok, i think this is what is happening (after comparing what AppCode does with Xcode). Xcode reindexes all files modified by the refactoring AND their dependancies, whilst AppCode only reindexes the affected files. a bug in Xcode imho ...

Resources