How to use the promise function from fs

Find comprehensive JavaScript fs.promise code examples handpicked from public code repositorys.

51
52
53
54
55
56
57
58
59
60
 * Writes the Podfile in the given directory.
 */
async writeAsync(contents: string) {
  let directory = this.settings.xcodeProjectDirectory;
  let podfilePath = path.join(directory, 'Podfile');
  await fs.promise.writeFile(podfilePath, contents, 'utf8');
}

/**
 * Creates a Podfile in the given directory with the help of `pod`
fork icon8
star icon0
watch icon2

+ 3 other calls in file