lib/zerg_xcode/plugins/retarget.rb in zerg_xcode-0.2.1 vs lib/zerg_xcode/plugins/retarget.rb in zerg_xcode-0.3

- old
+ new

@@ -1,8 +1,7 @@ class ZergXcode::Plugins::Retarget include ZergXcode::Objects - XcodeObject = ZergXcode::XcodeObject def help {:short => 'reassign files to a target or set of targets', :long => <<"END" } Usage: retarget project_path pattern [target target..] @@ -75,13 +74,10 @@ file_ref = file[:object] next if already_in.include? file phase_type = file_phases[file] phase = target['buildPhases'].find { |p| p['isa'] == phase_type } unless phase - phase = XcodeObject.new 'isa' => phase_type, 'dependencies' => [], - 'files' => [], - 'buildActionMask' => '2147483647', - 'runOnlyForDeploymentPostprocessing' => '0' + phase = PBXBuildPhase.new_phase phase_type target['buildPhases'] << phase end phase['files'] << build_files[file] end end