def read_pbx(pbx_file, ignore_unknown_objects=False): f = open(pbx_file) r = NSPlistReader(f) plist = r.read() project = PBXProjFile(plist, ignore_unknown_objects=False) r.close() return project
def read(fname_or_f): #open file if fname_or_f is a string #else use it as f if isinstance(fname_or_f, str) or isinstance(fname_or_f, unicode): f = open(fname_or_f) else: f = fname_or_f #read project reader = NSPlistReader(f) return PBXProjFile(reader.read(), encoding=reader.get_encoding())
def read(fname): f = open(fname) reader = NSPlistReader(f) return PBXProjFile(reader.read())