I want to echo
files that does not contain a substring "cds" or "rna" in their filenames.
I use the following code:
for genome in *
do
if [ ! "$genome" == *"cds"* ] || [ ! "$genome" == *"rna"* ]
then
echo $genome
fi
done
The code does not return any error but it keeps printing files that have the substrings indicated in the file name. How can I correct this? Thank you!