basename->dirname in qsub submited script generated by R