options to readdir. Also it now reads the source path from the pipeline.