I would like to modify this code to return an empty line if no match is found by grep:
while read vl ; do grep "^$vl" Table_S4.tab ; done < 1
while read vl; do
grep "^$vl" Table_S4.tab || printf "\n"
done < 1
If grep
doesn't find a match, the printf
command will be run and output an empty line.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With