added pdf dep and extension for write file