We've got a PHP application and want to count all the lines of code under a specific directory and its subdirectories.
(我们有一个PHP应用程序,并希望计算特定目录及其子目录下的所有代码行。)
We don't need to ignore comments, as we're just trying to get a rough idea. (我们不需要忽略评论,因为我们只是想弄清楚。)
wc -l *.php
That command works great within a given directory, but ignores subdirectories.
(该命令在给定目录中运行良好,但忽略子目录。)
I was thinking this might work, but it is returning 74, which is definitely not the case... (我当时认为这可行,但它正在返回74,绝对不是这样......)
find . -name '*.php' | wc -l
What's the correct syntax to feed in all the files?
(提供所有文件的正确语法是什么?)
ask by user77413 translate from so 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…