File:  [Power 6/32 Unix Tahoe 4.2BSD] / cci / usr / src / usr.lib / learn / editor / L35.2a
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs
Sun Jul 28 12:24:19 2019 UTC (7 years ago) by root
Branches: bsd, MAIN
CVS tags: v12b, v121, HEAD
Power 6/32 Unix version 1.2b

#print
The '*' character is also used in the editor patterns (the regular
expressions) but it has quite a different meaning from '*'
as used in filenames.  In the editor it means "any
number of repetitions of the previous character."  Thus
  a*
might match "a" or "aa" or "aaa" or "aaaa" and so on.
It might also match nothing, because "any number
of repetitions" includes "zero"!  Perhaps it
will be clearer after you do the following example.
Note what happens to the two lines.  Type

ex file
1,2p
1s/xa*/xy/
2s/xa*/xy/
1,2p
wq
ready
#create Ref
abxy
abxycd
#create file
abxaaa
abxcd
#user
#cmp file Ref
#log
#next
35.2b 5

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.