lib/gym/generators/build_command_generator.rb in gym-0.7.2 vs lib/gym/generators/build_command_generator.rb in gym-0.7.3
- old
+ new
@@ -61,10 +61,18 @@
suffix << "CODE_SIGN_IDENTITY='#{Gym.config[:codesigning_identity]}'" if Gym.config[:codesigning_identity]
suffix
end
def pipe
- ["| xcpretty"]
+ ["| tee '#{xcodebuild_log_path}' | xcpretty"]
+ end
+
+ def xcodebuild_log_path
+ file_name = "#{Gym.project.app_name}-#{Gym.config[:scheme]}.log"
+ containing = File.expand_path("~/Library/Logs/gym")
+ FileUtils.mkdir_p(containing)
+
+ return File.join(containing, file_name)
end
# The path to set the Derived Data to
def build_path
unless @build_path