notegrep: "cl" parameter
This commit is contained in:
parent
efe588b12d
commit
2552a92a06
2 changed files with 12 additions and 0 deletions
|
@ -124,6 +124,9 @@ function notegrep() {
|
|||
case $option in
|
||||
-sc | --split-char)
|
||||
. ~/.shellnotes/util/notegrep/sc.sh
|
||||
;;
|
||||
-cl | --count-lines )
|
||||
. ~/.shellnotes/util/notegrep/cl.sh
|
||||
;;
|
||||
*)
|
||||
echo "Invalid parameter. Proceeding in normal grep mode."
|
||||
|
|
9
util/notegrep/cl.sh
Normal file
9
util/notegrep/cl.sh
Normal file
|
@ -0,0 +1,9 @@
|
|||
:<<'info'
|
||||
shellnotes - cl.sh
|
||||
(C) Dimitris Marakomihelakis
|
||||
Released under the "All rights reserved" category. See the RIGHTS.txt file
|
||||
in /docs/github/ for its full text.
|
||||
info
|
||||
|
||||
out="$(grep $regex $DEFAULT_PATH/$notename | wc -l)"
|
||||
echo "Compressed $out lines of grep output."
|
Loading…
Reference in a new issue