Skip to content

Commit 44eeb53

Browse files
committed
feat(utils): add function "mkdir"
1 parent 8de7853 commit 44eeb53

File tree

1 file changed

+9
-0
lines changed
  • packages/mongodb-memory-server-core/src/util

1 file changed

+9
-0
lines changed

packages/mongodb-memory-server-core/src/util/utils.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -270,3 +270,12 @@ export async function checkBinaryPermissions(path: string): Promise<void> {
270270
throw err;
271271
}
272272
}
273+
274+
/**
275+
* Make Directory, wrapper for native mkdir with recursive true
276+
* @param path The Path to create
277+
* @returns Nothing
278+
*/
279+
export async function mkdir(path: string): Promise<void> {
280+
await fspromises.mkdir(path, { recursive: true });
281+
}

0 commit comments

Comments
 (0)