#! /bin/bash
for f in ./pdbqt/*.pdbqt; do
b=`basename $f .pdbqt`
echo Processing ligand ${b}
mkdir -p ${b}
for ((n=1;n<2;n++))
do
outfile="out""$n"
logfile="log""$n" 
vina --config conf.txt --ligand ${f} --log ${b}"/"$logfile".txt" --out ${b}"/"$outfile".pdbqt"
done
done
