The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
Google UNIX.COM



View Single Post in UNIX Forums - Click on the Thread or Permalink to View Entire Thread -->
  #2 (permalink)  
Old 01-30-2008
Smiling Dragon's Avatar
Smiling Dragon Smiling Dragon is offline
Disorganised User
 

Join Date: Nov 2007
Location: New Zealand
Posts: 742
Post

Very do-able but not as easily as you'd hope:
Code:
for file in *.dna; do blastall -p blastn -i $file -o ${file}.output
Will produce a bunch of files *.dna.output
To get *.output:
Code:
for file in *.dna; do blastall -p blastn -i $file -o `echo $file | sed 's/dna$//'`.output
Incidentally, windows actually lets you do something like this:
Code:
blastall -p blastn -i *.dna -o *.output
But only for certain commands - it seems to depend on how you hold your mouth when you do it.
Reply With Quote