Skip to content
This repository was archived by the owner on Sep 14, 2022. It is now read-only.

Commit 3fe2c91

Browse files
committed
feat: add rm-rf scripts
1 parent f9e2695 commit 3fe2c91

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

generators/gen-libs.ts renamed to scripts/gen-libs.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import { createMinifier } from "dts-minify";
2020
function resolveToOutput(relPath: string): string {
2121
return path.resolve(OUTPUT_PATH, relPath);
2222
}
23-
23+
2424
function toProperty(fileName: string, text: string) {
2525
return `["${fileName}"]: \`${minifiler
2626
.minify(text)

scripts/rm-rf.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
import fs from "fs";
2+
import path from "path";
3+
4+
(function rmrf([dirPath]: string[]) {
5+
try {
6+
fs.rmdirSync(path.resolve(process.cwd(), dirPath), { recursive: true });
7+
} catch {}
8+
})(process.argv.slice(2));

0 commit comments

Comments
 (0)