Update init. Remove uneccessary directores creation

This commit is contained in:
Benjamin Toby 2026-03-22 05:06:36 +01:00
parent 32056b5cb6
commit 9f619c8898
3 changed files with 5 additions and 1 deletions

View File

@ -18,6 +18,8 @@ export default async function () {
for (let i = 0; i < keys.length; i++) { for (let i = 0; i < keys.length; i++) {
const key = keys[i]; const key = keys[i];
const dir = dirNames[key]; const dir = dirNames[key];
if (!dir.match(/\//))
continue;
if (!existsSync(dir) && !dir.match(/\.\w+$/)) { if (!existsSync(dir) && !dir.match(/\.\w+$/)) {
mkdirSync(dir, { recursive: true }); mkdirSync(dir, { recursive: true });
continue; continue;

View File

@ -27,7 +27,7 @@
], ],
"scripts": { "scripts": {
"dev": "tsc --watch", "dev": "tsc --watch",
"git:push": "tsc --noEmit && tsc && git add . && git commit -m 'Update HMR logic. Refresh on server props update.' && git push", "git:push": "tsc --noEmit && tsc && git add . && git commit -m 'Update init. Remove uneccessary directores creation' && git push",
"compile": "bun build ./src/commands/index.ts --compile --outfile bin/bunext --minify", "compile": "bun build ./src/commands/index.ts --compile --outfile bin/bunext --minify",
"build": "tsc", "build": "tsc",
"test": "bun test --max-concurrency=1" "test": "bun test --max-concurrency=1"

View File

@ -30,6 +30,8 @@ export default async function () {
const key = keys[i]; const key = keys[i];
const dir = dirNames[key]; const dir = dirNames[key];
if (!dir.match(/\//)) continue;
if (!existsSync(dir) && !dir.match(/\.\w+$/)) { if (!existsSync(dir) && !dir.match(/\.\w+$/)) {
mkdirSync(dir, { recursive: true }); mkdirSync(dir, { recursive: true });
continue; continue;