Improve grep syntax.

This commit is contained in:
Manuele Simi 2021-02-16 15:23:46 -05:00
parent 76ec776767
commit 08296aacd2
1 changed files with 1 additions and 1 deletions

View File

@ -1,7 +1,7 @@
#!/usr/bin/env bash
out=`find . -name '*.java' -exec grep 'http://' /dev/null {} +`
echo "${out}"
if [[ "$(grep 'java' ${out})" ]]; then
if [[ "$(grep '\.java' <<< ${out})" ]]; then
echo "HTTP protocol found"
else
echo "HTTP protocol not found"