Can someone explain me what does the following script?
#!/bin/bash
for F in *.txt; do
K=`grep abc $F`
echo $K
if ["$K" != ""]; then
echo $F
fi
done
I tested it and when it finds a txt file that contains the "abc" string, on prompt appears
`"./a.sh: line 5: [abc: command not found"`
error, otherwise appears the name of txt file that doesn't contain the "abc" string.