Library for dealing with project files (*.xcodeproj/*.pbxproj) in AppCode

Hi there!

For some nifty reason I need to implement a (hopefully) open source tool that changes .pbxproj files (adds some refs, deps, changes params, etc) without breaking the whole file. Unfortunately Apple doesn't like other devs dealing with the old plist style files so it's quite hard to write an .xcodeproj file in old format. And I don't want to change its structure a lot to simplify merges between branches (i.e., all the Xcode generated comments should be preserved, etc).

As far as I can see, AppCode is one of the IDEs that can write the .pbxproj files correctly. Do you use a specific library for that? I wasn't able to find a good one. In case you use your own implementation, aren't you going to release it to the open source world? The only things needed are the model and filters for the .pbxproj files. It should be a tiniest part of the AppCode :)

If it's not possible (which I am afraid of) I'll need to go the hard way and implement such lib from scratch. Do you have any suggestions for me? Do I miss an easy way to do .pbxproj modifications?

Comment actions Permalink

currently, we don't have plans to release any public library.
I suggest contacting CocoaPods ( folks - they do project modification and, probably, have public code for this.

Comment actions Permalink

These guys are using CoreFoundation API to write kCFPropertyListXMLFormat_v1_0 formatted plist and the usual .pbxproj is

in kCFPropertyListOpenStepFormat. According to the Foundation documentation "
constant is not supported for writing. It can be used only for reading old-style property lists.
" (NSPropertyListOpenStepFormat is a mapping for 
). I'll recheck the CF version but I doubt it will work and even if it does I doubt it preserves the comments, order, etc.

Anyway, thanks for an answer! :)
Comment actions Permalink

I see,
try reaching Jasper Blues - he once mentioned that he worked on an Xcode project editor (see,


Please sign in to leave a comment.