Explorar o código

grep: add line number

Antonio %!s(int64=9) %!d(string=hai) anos
pai
achega
b0adce01cb
Modificáronse 1 ficheiros con 4 adicións e 0 borrados
  1. 4 0
      pages/common/grep.md

+ 4 - 0
pages/common/grep.md

@@ -23,6 +23,10 @@
 
 `grep -c {{something}} {{file_path}}`
 
+- print line number for each match
+
+`grep -n {{something}} {{file_path}}`
+
 - use the standard input instead of a file
 
 `cat {{file_path}} | grep {{something}}`