Hi everyone ! I have some problems with my bash script. I have a text file( filt80more.txt) that contain my best alignments and I want to compare the alignments in that text file(filt80more.txt) with directory that contain all alignments(Tcoffee_outputs/E.aa.fa.aln) and take out that best alignments from directory(Tcoffee_outputs/E.aa.fa.aln) to my new folder (Filtrerad). I will be very grateful for your help :)
for FILE1 in Tcoffee_outputs/E*.aa.fa.aln;
do
for FILE2 in `cat filt80more.txt`;
do
if [ $( diff "${FILE1}" "${FILE2}" ) == 0 ];
then
mv Tcoffee_outputs/$FILE1~/Users/vazgengevorgyan/Desktop/perl_krill/merged_min_4_species_filtered/Filtrerad/$FILE1
break
fi
done
done
and what exactly is the problem with the script? (I'm not saying it's correct otherwise!). do you get any errors/warnings? or is it just not doing what you expect?
L.
Hi :) I get this error: diff: EOG090Y02RG: No such file or directory getfiles.sh: line 105: [: ==: unary operator expected