Skip to content

Commit

Permalink
refactor: remove make-dir as a dep (#746)
Browse files Browse the repository at this point in the history
* refactor: remove `make-dir` as a dep

* fix: oops

not even sure if this will work
  • Loading branch information
kanadgupta authored Oct 6, 2023
1 parent 5259bb7 commit ab41a72
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion packages/api/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@
"lodash.deburr": "^4.1.0",
"lodash.setwith": "^4.3.2",
"lodash.startcase": "^4.4.0",
"make-dir": "^4.0.0",
"oas": "^22.0.0",
"ora": "^5.4.1",
"prompts": "^2.4.2",
Expand Down
5 changes: 2 additions & 3 deletions packages/api/src/storage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import type { OASDocument } from 'oas/rmoas.types';
import fs from 'node:fs';
import path from 'node:path';

import makeDir from 'make-dir';
import ssri from 'ssri';
import validateNPMPackageName from 'validate-npm-package-name';

Expand Down Expand Up @@ -57,9 +56,9 @@ export default class Storage {
return;
}

Storage.dir = makeDir.sync(path.join(process.cwd(), '.api'));
Storage.dir = fs.mkdirSync(path.join(process.cwd(), '.api'), { recursive: true }) as string;

makeDir.sync(Storage.getAPIsDir());
fs.mkdirSync(Storage.getAPIsDir(), { recursive: true });
}

/**
Expand Down

0 comments on commit ab41a72

Please sign in to comment.