refactor crash message + fix wording

This commit is contained in:
Laurent Sansonetti
2013-08-07 15:17:28 +02:00
parent a8c7e4f6e1
commit 9d95a7211d
3 changed files with 13 additions and 12 deletions

View File

@@ -286,5 +286,16 @@ module Motion; module Project
def datadir(target=deployment_target)
File.join(motiondir, 'data', template.to_s, target)
end
def print_crash_message
$stderr.puts ''
$stderr.puts '=' * 80
$stderr.puts <<EOS
The application terminated. A crash report file may have been generated by the
system, use `rake crashlog' to open it. Use `rake debug=1' to restart the app
in the debugger.
EOS
$stderr.puts '=' * 80
end
end
end; end

View File

@@ -111,15 +111,7 @@ END
at_exit { system("stty echo") } if $stdout.tty? # Just in case the simulator launcher crashes and leaves the terminal without echo.
Signal.trap(:INT) { } if ENV['debug']
system "#{env} #{sim} #{debug} #{family_int} #{target} \"#{xcode}\" \"#{app}\" #{app_args}"
if $?.exitstatus != 0
$stderr.puts '=' * 80
$stderr.puts <<EOS
The application crashed. A crash report file may have been generated by the
system, use `rake crashlog' to open it. Use `rake debug=1' to restart the app
in the debugger.
EOS
$stderr.puts '=' * 80
end
App.config.print_crash_message if $?.exitstatus != 0
end
desc "Create an .ipa archive"

View File

@@ -65,9 +65,7 @@ task :run do
at_exit { system("stty echo") } if $stdout.tty? # Just in case the process crashes and leaves the terminal without echo.
Signal.trap(:INT) { } if ENV['debug']
system "#{env} #{sim} #{debug} #{target} \"#{exec}\" #{app_args}"
if $?.exitstatus != 0
$stderr.puts "\nThe application crashed. A crash report file may have been generated by the system, use `rake crashlog' to open it. Use `rake debug=1' to restart the app in the debugger."
end
App.config.print_crash_message if $?.exitstatus != 0
end
desc "Run the test/spec suite"