Join David D. Levine for an in-depth discussion in this video Regular expression examples, part of Learning vi.
…I'm going to show you some examples of the regular expression meta-characters we've…just discussed.…We'll use our Purloined Letter file.…If you search for…just plain text, like the letters not, then it finds the not in Dunot.…n shows another not.…n shows another not, this one embedded in the word another.…n, here's another not, embedded in the word notions.…1G to go to the back of the file.…If you look for, n.t, which is an n followed by any character…followed by a t, then, in this case it finds n space t.…
n, again, it finds n o t.…n, n space t.…n, n space t again.…n, n space t again.…n, not.…n, n space t.…n, n space t.…n, not.…n, not.…n, n space t.…n, nat, and so on.…It'll find an n, followed by anything, followed by a t.…1G.…You see near the middle of the screen the words, Number 33, capital N,…little o, period, 33.…
If I search for capital N, o, period, it finds No period,…n, but it also finds capital NOT.…Remember that the period matches any character.…n, it finds No question mark as well.…1G to return to the top of the file.…
AuthorDavid D. Levine
- Entering and leaving vi
- Understanding the Command, Insert, and Colon modes
- Moving around in files
- Editing text
- Moving content with delete, yank, and put
- Searching with regular expressions
- Customizing vi
- Filtering text through shell commands
Skill Level Beginner
1. Exploring vi
What is vi?2m 26s
2. Getting Started with vi
3. Moving Around within a File
4. Basic Text Editing
5. Undo, Repeat, Yank, and Put
6. Search and Replace
7. Advanced Editing Features
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.