Red Hat NETSCAPE MANAGEMENT SYSTEM 6.0 - CUSTOMIZATION User Manual Page 277

  • Download
  • Add to my manuals
  • Print
  • Page
    / 300
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 276
17.4 Identifying and Working with File Types 265
sneakers.txt
Youll probably use the asterisk (*) most frequently when youre searching. The asterisk will search
out everything that matches the pattern youre looking for. So even by typing:
ls *.txt
or:
ls sn*
youd nd sneakers.txt except that as time goes on, there will be more text les, and theyll all
show up because they match the pattern youre searching for.
Ithelps,then,tonarrowyoursearchasmuchaspossible.
One way to narrow the search might be to use the question mark symbol (?). Like the asterisk, using
? can help locate a le matching a search pattern.
In this case, though, ? is useful for matching a single character so if you were searching for
sneaker?.txt,youdgetsneakers.txt as a result and/or sneakerz.txt, if there were such
a lename.
When an asterisk, for example, just happens to be part of a lename, such as might be the case if the
le sneakers.txt was called sneak*.txt,thats when regular expressions can come in handy.
Regular expressions are more complex than the straightforward asterisk or question mark.
Using the backslash (\), you can specify that you dontwanttosearchouteverything by using the
asterisk, but youre instead looking for a le with an asterisk in the name.
If the le is called sneak*.txt, then, type:
sneak\*.txt
Here is a brief list of wildcards and regular expressions:
* Matches all characters
? Matches one character in a string (such as sneaker?.txt)
\* Matches the * character
\? Matches the ? character
\) Matches the ) character
Page view 276
1 2 ... 272 273 274 275 276 277 278 279 280 281 282 ... 299 300

Comments to this Manuals

No comments