-
Notifications
You must be signed in to change notification settings - Fork 27
/
Copy pathmode.vroom
39 lines (23 loc) · 904 Bytes
/
mode.vroom
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
By default, output lines are matched in verbatim mode:
% The quick brown fox jumps over the lazy dog?
The quick brown fox jumps over the lazy dog?
You make modes explicit with control blocks:
The quick brown fox jumps over the lazy dog? (verbatim)
You may also use `glob` mode and `regex` mode. * and ? are expanded in glob mode
and may be escaped. This works like python's fnmatch.
The * * ??? jumps over the * dog[?] (glob)
Regexes are python-style.
\w+ \w+ brown fox .* lazy dog\? (regex)
Python regex flags etc. all work:
(?i)\w+ \w+ BROWN FOX .* LAZY DOG. (regex)
We suggest you use flags at the beginning of the regex, so as to not confuse
vroom into thinking you're misspelling line controls.
System capture lines are matched in regex mode by default:
:.!echo 'Hello.'
! echo .*
Hello.
You may override that.
@clear
:.!echo '.*'
! echo '.*' (verbatim)
.*