shellnotes/util/notegrep/sf.sh
dmarakom6 e3f7e7414f Fix output bug
Fix -cf and -sf returning "No such file" or proceeding in normal grep mode
2021-06-28 13:42:57 +03:00

14 lines
329 B
Bash

:<<'info'
shellnotes - sf.sh
(C) Dimitris Marakomihelakis
Released under the "All rights reserved" category. See the RIGHTS.txt file
in /docs/github/ for its full text.
info
files="$(grep -rwl $regex $DEFAULT_PATH/* | wc -l)"
if [ $files -ge 1 ]; then
grep -rwl $regex $DEFAULT_PATH/*
else
echo "No matching files found."
fi