What does rpm -qa |grep th* (as compared to rpm -qa |grep th) display?
rpm -qa |grep th displays packages with "th" in their name.
What do rpm -qa |grep th* and rpm -qa |grep *th display? I don't quite understand the output. rpm -qa |grep th* seems to display any package with "t" in the name?! Some concept teaching required here :) Thanks ! |
Grep takes regular expressions, so "grep th*" is actually equivalent to "any line that has the letter 't' and any number of 'h'(including 0)".
If you want to grep for packages that start with "th", try Code:
rpm -qa | grep ^th |
Could you elaborate on "regular expressions"? Does "grep th3" refers to "any line that has the letter 't' and 3 instances of 'h'"?
Thanks ! Quote:
|
All times are GMT -5. The time now is 07:58 AM. |