Translations:Linux introduction/26/en

From Alliance Doc
Jump to navigation Jump to search

The text to be searched for can also be variable. For example, to look for the text number 10 or number 11, etc. with any number between 10 and 29, the following command can be used:

Question.png
[name@server ~]$ grep 'number [1-2][0-9]' file

A regular expression must be used for the search text. To learn more, see this guide to regular expressions.