aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRafael Mendonça França <rafaelmfranca@gmail.com>2012-12-03 09:28:24 -0800
committerRafael Mendonça França <rafaelmfranca@gmail.com>2012-12-03 09:28:24 -0800
commitd7fdcc87171ca0098522c05f844b3ec24a14b0b7 (patch)
treecc4f4ef900e4c3c55c6f126a749b38a28c334854
parent4fac8c651a0db3b2e49b6eb2d97424a55d81f8e0 (diff)
parent0f47c496781fda4ce35f79bea9fb03e6b29c1867 (diff)
downloadrails-d7fdcc87171ca0098522c05f844b3ec24a14b0b7.tar.gz
rails-d7fdcc87171ca0098522c05f844b3ec24a14b0b7.tar.bz2
rails-d7fdcc87171ca0098522c05f844b3ec24a14b0b7.zip
Merge pull request #8407 from kennyj/fix_profiler_comments
Fix wrong doc and message about rails profiler.
-rw-r--r--guides/source/performance_testing.md4
-rw-r--r--railties/lib/rails/commands/profiler.rb2
2 files changed, 3 insertions, 3 deletions
diff --git a/guides/source/performance_testing.md b/guides/source/performance_testing.md
index b84c5d1732..a07f64ec29 100644
--- a/guides/source/performance_testing.md
+++ b/guides/source/performance_testing.md
@@ -559,9 +559,9 @@ Usage: rails profiler 'Ruby.code' 'Ruby.more_code' ... [OPTS]
Default: 1
-o, --output PATH Directory to use when writing the results.
Default: tmp/performance
- --metrics a,b,c Metrics to use.
+ -m, --metrics a,b,c Metrics to use.
Default: process_time,memory,objects
- -m, --formats x,y,z Formats to output to.
+ -f, --formats x,y,z Formats to output to.
Default: flat,graph_html,call_tree
```
diff --git a/railties/lib/rails/commands/profiler.rb b/railties/lib/rails/commands/profiler.rb
index 3f6966b4f0..315bcccf61 100644
--- a/railties/lib/rails/commands/profiler.rb
+++ b/railties/lib/rails/commands/profiler.rb
@@ -8,7 +8,7 @@ def options
defaults = ActiveSupport::Testing::Performance::DEFAULTS
OptionParser.new do |opt|
- opt.banner = "Usage: rails benchmarker 'Ruby.code' 'Ruby.more_code' ... [OPTS]"
+ opt.banner = "Usage: rails profiler 'Ruby.code' 'Ruby.more_code' ... [OPTS]"
opt.on('-r', '--runs N', Numeric, 'Number of runs.', "Default: #{defaults[:runs]}") { |r| options[:runs] = r }
opt.on('-o', '--output PATH', String, 'Directory to use when writing the results.', "Default: #{defaults[:output]}") { |o| options[:output] = o }
opt.on('-m', '--metrics a,b,c', Array, 'Metrics to use.', "Default: #{defaults[:metrics].join(",")}") { |m| options[:metrics] = m.map(&:to_sym) }