In Windows, I would have done a search for finding a word inside a folder.
(在Windows中,我会搜索在文件夹中查找单词。)
Similarly, I want to know if a specific word occurs inside a directory containing many sub-directories and files. (同样,我想知道在包含许多子目录和文件的目录中是否出现特定单词。)
My searches for grep syntax shows I must specify the filename, ie grep string filename
. (我对grep语法的搜索显示我必须指定文件名,即grep string filename
。)
Now, I do not know the filename, so what do I do?
(现在,我不知道文件名,所以我该怎么办?)
A friend suggested to do grep -nr string
, but I don't know what this means and I got no results with it (there is no response until I issue a ctrl + c ). (一位朋友建议做grep -nr string
,但我不知道这意味着什么,我没有得到任何结果(在我发出ctrl + c之前没有响应)。)
ask by kiki translate from so 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…