0
我是bash脚本编写的新手,但我想将某些文件设置为bash脚本中for循环的变量。我有这样的代码:如何在bash中将文件设置为变量
a=home/my_directory/*.fasta
b=home/my_directory/*.aln
for i in {1..14} # I have 14 files in my_directory with file extension .fasta
do
clustalo -i $a -o $b # clustalo is a command of Clustal Omega software, -i is
# input file, -o is output file
done
我只想在my_directory中使用我所有的fasta文件,并创建另外14个新的aln文件。但有了这个代码,它不起作用,因为Clustal程序不能识别这个集合文件。所以,如果你能帮助,我会非常感激。
是否有可能将这些新文件保存到新目录? – user1997808