Method: Xcode::Project#save

Defined in:
lib/xcode/project.rb

#save(path) ⇒ Object

Note:

currently this does not support saving the workspaces associated with the project to their new location.

Saves the current project at the specified path.

Parameters:

  • path (String)

    the path to save the project



217
218
219
220
221
222
223
224
225
226
227
# File 'lib/xcode/project.rb', line 217

def save(path)

  Dir.mkdir(path) unless File.exists?(path)
  project_filepath = "#{path}/project.pbxproj"

  # @toodo Save the workspace when the project is saved
  # FileUtils.cp_r "#{path}/project.xcworkspace", "#{path}/project.xcworkspace"

  Xcode::PLUTILProjectParser.save "#{path}/project.pbxproj", to_xcplist

end