Xcode "File Inspector" change default file type for custom extension

Hi,
I'm adding a raw data file to my project, programatically using script.
After launching Xcode the "File Inspector" is identifying the data file as "Rez source" and compilation fails as Rez tries to compile that file. It should not be compiled.
If I manually change it's file type to "Default Data" it compiles properly.
My Jenkins build are breaking due to Rez issues.

I wanted to know is there a way/API to:
  1. Change the type of file(Rez -> data) after adding it in Xcode using scripts.

  2. Ignore a file from compilation but keep it as part of bundle.

I do not have option of adding files from UI, I need to do it using scripts.

I'm new to Apple environment, please pardon my lack of knowledge and please suggest if I missed any obvious steps.

Thanks
For anyone looking for same thing.
I found the solution, we need to change the file type in file "project.pbxproj" in directory "<project_name>.xcodeproj".

Example:
I changed line
/*B.data */ = {isa = PBXFileReference; lastKnownFileType = source.rez; name = B.data; path = ../B.data; sourceTree = "<group>"; };

to
/*B.data */ = {isa = PBXFileReference; lastKnownFileType = file; name = B.data; path = ../B.data; sourceTree = "<group>"; };

After that restart xcode, your file type in "File Inspector" will change from 'Rez source' to ' Default data'

Xcode "File Inspector" change default file type for custom extension
 
 
Q