Fetch the contents of specified files and folders into a text file