Add functions to read and write files. The functions must have the same interface as those in Node.js fs module