[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: which is the best command to use

On Tue, Dec 27, 2011 at 08:57:55PM +0800, lina wrote:
> Hi,
> I have two questions, wish to get advice,
> Question 1:
> For a series of files:
> cat  a_*.o* | grep "WARNING"
> some file like a_1.o12 has WARNING, but others does not have WARNING
> How can I let grep returns the filename?

try "grep -H"
in order to get the filename.

Wilko Fokken                            Education is a man's going
Landschaftspolder 67                    from cocksure ignorance
D-26831 Bunde                           to thoughtful uncertainty.
Tel. 04953-9219882

Reply to: