Sunday, September 14, 2008

Subversion under XCode

Create repository

svnadmin create /Users/sagasu/Worek/Workspaces/svnRepository/magicNumbers

My project name is Magic Numbers so the name of the repository is magicNumbers. You can specify any path you wish.

Integrate subversion repository with XCode SCM system.

Create a new repository configuration.

Click + (plus) button at the left button, to add a new repository.

Specify a name, and SCM too that you want to use (Subversion).

Fill the URL field. After filling URL field path and scheme will be automatically filled.

In the Repositories window choose Import, and choose a project that you want to add to the repository. And you are done.

One of the ways to make current project aware that it is inside a subversion control system is to navigate to the place where the project is held and delete it (you can use Finder to do it). Then open XCode and check in the project to this same directory (or different if you wish) from which it was removed. Now XCode will allow you to manage your files from XCode.

Developing under OS X

I've been using Tiger (OS X) for a year now, but few days ago I installed Leopard. I decided to upgrade to Leopard because there is no iPhone sdk for Tiger. Leopard ships with a newer version of XCode. I tried XCode few time before, but somehow I did not enjoyed it. I decided to give it one more try, mainly because recently I've been playing with cocoa framework, and it is easy to create interfaces in Interface Builder, which integrates great with XCode. Before I used to develop applications under Emacs using Carbon framework, because I did not enjoyed Objective-C. I believe that the thing that turned my attention from Objective-C was XCode. XCode had, and still has a really poor word completion system, due to that It doesn't help a nub programmer to find methods/objects that nub is looking for. This forced me to spend tremendous amount of time searching thru documentation/language reference, sometimes just to find out that this feature is not implemented and I need to do it on my own. Now when I am more familiar with OS X development platform is time to give XCode one more chance. What I like in OS X development is Interface Designer - it is nice, good looking, easy to use, and so on. Unfortunately it lacks many features, like shortcuts - I don't want to drag and drop things (control drop things). Interface Designer opens many windows, there is no easy way to move between them easily, or just define new key shortcuts to do an operation. So as a conclusion Interface Designer is nice to learn, easy to use to create simple operations, but later when one is more familiar with it, it takes to much time to do something. Let's go back to XCode; it still lacks a support for redefining key bindings - to do that I need to modify map files for entire system (also for other applications). It lacks refactoring tools that Eclipse has. Thanks god it has a not bad integration with external editors - like Emacs. Thanks to that I don't need to use mouse to open other file, or open test class for a class that I am currently editing. The feature that it really lucks is something like ctr+r or ctr+t in Eclipse (open class/resource that is included in project, just by typing it's name). XCode has also a good sides - it shows errors, and warnings really nicely. Debugger works great.

Wednesday, February 13, 2008

Design Patterns as Higher Order Datatype Generic Programs

Lately I was struggling with some other issues, that is why I'm updating my blog now with some older issues.

On 14 of November I went to the LHUG meeting to listen to the speech about Design Patterns as Higher-Order Datatype-Generic Programs. There is a video from this event. As always I asked some silly questions. The speech was excellent, but the best part was the beer after the event. I had an opportunity and pleasure to talk with Dr Jeremy Gibbons and discuss even more research that he did. As always beer conversation lead to the deeper thoughts about nature of programming languages. Enjoy the video.