use stdin to support i.e. spaces in filenames