2015年2月6日 星期五

[Linux] find& grep

When trace the source code of a new project which from a customer or the online opensource, we often need "find" some file name or "grep" content in a file.

Below is the instructions to achieve above behavior.

$find . -name "*.i" -print

means find all the file name end with ".i" from current folder and all folders under current folder..

$grep -rn "test" .

means find text "test" in current folder and all folders under current folder.

沒有留言:

張貼留言