Skip to content

Commit 9a9f874

Browse files
committed
Updated PATTERN examples in CLI help output
[Closes #625]
1 parent c0b6f1f commit 9a9f874

File tree

2 files changed

+9
-4
lines changed

2 files changed

+9
-4
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@
22

33
## 1.3.2 _(October 19, 2015)_
44

5+
- `UI`
6+
- `CLI`
7+
- Help output
8+
- Simplified `PATTERN` examples.
9+
- Replaced `test.com` with `example.com`.
510
- Browser
611
- Configure PhantomJS to accept any SSL version to allow for easier interception.
712
- `HTTP`

ui/cli/framework/option_parser.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -138,8 +138,8 @@ def scope
138138

139139
on( '--scope-url-rewrite PATTERN:SUBSTITUTION',
140140
'Rewrite URLs based on the given PATTERN and SUBSTITUTION.',
141-
'To convert: http://test.com/articles/some-stuff/23 to http://test.com/articles.php?id=23',
142-
'Use: /articles\/[\w-]+\/(\d+)/:articles.php?id=\1'
141+
'To convert: http://example.com/articles/some-stuff/23 to http://example.com/articles.php?id=23',
142+
'Use: articles/[\w-]+/(\d+):articles.php?id=\1'
143143
) do |rule|
144144
pattern, substitution = rule.split( ':', 2 )
145145
options.scope.url_rewrites[ Regexp.new( pattern ) ] =
@@ -191,9 +191,9 @@ def audit
191191
on( '--audit-link-template TEMPLATE', Regexp,
192192
'Regular expression with named captures to use to extract input information from generic paths.',
193193
"To extract the 'input1' and 'input2' inputs from:",
194-
' http://test.com/input1/value1/input2/value2',
194+
' http://example.com/input1/value1/input2/value2',
195195
'Use:',
196-
' /input1\/(?<input1>\w+)\/input2\/(?<input2>\w+)/',
196+
' input1/(?<input1>\w+)/input2/(?<input2>\w+)',
197197
'(Can be used multiple times.)'
198198
) do |pattern|
199199
# We merge this way to enforce validation from the options group.

0 commit comments

Comments
 (0)