Use pathlib for handling file manipulations