Skip to content

Commit f75806b

Browse files
committed
Revert "Update rubybench_runner guide"
This reverts commit d0df3ac. This gem is not officially under Rubybench and unreviewed yet so I'm reverting this for now.
1 parent d948242 commit f75806b

File tree

3 files changed

+4
-15
lines changed

3 files changed

+4
-15
lines changed

app/helpers/repos_helper.rb

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,4 @@ def show_gem_tip
55
@benchmark &&
66
@benchmark.category !~ /^discourse_/
77
end
8-
9-
def script_name
10-
@benchmark.script_url.match(/\/([^\/]+)$/)[1]
11-
end
128
end

app/views/repos/_script.html.haml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
- if script_url = benchmark.script_url
22
- if show_gem_tip
3-
!= t('repos.run_locally_tip', path: run_locally_path, script: script_name)
3+
%h4.l-align-center
4+
!= t('repos.run_locally_tip', path: run_locally_path)
45
%h2.l-align-center
56
= t('repos.script_title', graph_name: benchmark.category.humanize)
67

config/locales/en.yml

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -59,12 +59,7 @@ en:
5959
"%{category}" does not have any results. Please select another
6060
Benchmark Type.
6161
view_github: View on Github
62-
user_scripts: "user_scripts/%{name}"
63-
run_locally_tip: |
64-
<p>You can run this benchmark locally using the <code>rubybench_runner</code> gem:</p>
65-
<pre>gem install rubybench_runner
66-
rubybench_runner run rails/%{script}</pre>
67-
More details <a href="%{path}">here</a>.
62+
run_locally_tip: You can run this benchmark locally using the <code>rubybench_runner</code> gem. More details <a href="%{path}">here</a>.
6863

6964
index:
7065
commits_benchmark: Commits Benchmarks
@@ -126,10 +121,7 @@ en:
126121
</li>
127122
<li>Pick one of the <a href="https://rubybench.org/rails/rails/commits">available rails benchmarks</a> and copy the GitHub link of the script (it's the "View on Github" button).</li>
128123
<li>Run:
129-
<pre>rubybench_runner run rails/&lt;script_name&gt; --rails=/path/to/rails</pre>
130-
You can get <code>script_name</code> from the page of the benchmark that you want to run at rubybench.org.
131-
<br>
132-
If you have Rails cloned in your home directory, you can omit the <code>--rails</code> flag.
124+
<pre>rubybench_runner run rails &lt;script_url&gt; &lt;path_to_rails_clone&gt;</pre>
133125
</li>
134126
<li>If the benchmark requires a database server, then you need to specify the <code>--db</code> option. Run <code>rubybench_runner --help</code> for details.</li>
135127
</ul>

0 commit comments

Comments
 (0)