Issue
I want to use grep
to find the lines contain String
in all java files under current directory.
I tried:
grep -r "String" **/*.java
But it doesn't work:
grep : **/*.java: no such file or directory
How to write it?
UPDATE
I'm on windows, using the grep
provided by unxUtils
, which doesn't support --include
parameter. Is there any other way?
Solution
Use recursive grep:
grep -r "String" --include=*.java .
Answered By - anubhava Answer Checked By - Robin (WPSolving Admin)