From 6c7584eea5bf10285b3c5653019a3a5e1f6b5d23 Mon Sep 17 00:00:00 2001 From: Karanjot786 <99573351+Karanjot786@users.noreply.github.com> Date: Sun, 2 Aug 2026 03:19:33 +0000 Subject: [PATCH 1/2] docs: auto-generate CONTRIBUTORS.md [skip ci] --- CONTRIBUTORS.md | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/CONTRIBUTORS.md b/CONTRIBUTORS.md index 9ad7db5e3..bf1af24d7 100644 --- a/CONTRIBUTORS.md +++ b/CONTRIBUTORS.md @@ -4,7 +4,7 @@ We want to thank all the amazing contributors who have helped make TermUI what i | Avatar | Contributor | Contributions | | :---: | :--- | :---: | -| Karanjot786 | [@Karanjot786](https://github.com/Karanjot786) | 347 | +| Karanjot786 | [@Karanjot786](https://github.com/Karanjot786) | 348 | | Tomeshwari-02 | [@Tomeshwari-02](https://github.com/Tomeshwari-02) | 155 | | ionfwsrijan | [@ionfwsrijan](https://github.com/ionfwsrijan) | 92 | | srushti-panara | [@srushti-panara](https://github.com/srushti-panara) | 86 | @@ -144,7 +144,7 @@ We want to thank all the amazing contributors who have helped make TermUI what i | nkapoor175 | [@nkapoor175](https://github.com/nkapoor175) | 1 | | MeghPatel-007 | [@MeghPatel-007](https://github.com/MeghPatel-007) | 1 | | ezManish | [@ezManish](https://github.com/ezManish) | 1 | -| Novice47 | [@Novice47](https://github.com/Novice47) | 1 | +| manasvi-sahare | [@manasvi-sahare](https://github.com/manasvi-sahare) | 1 | | ShubhamSawant726 | [@ShubhamSawant726](https://github.com/ShubhamSawant726) | 1 | | Sneha6657 | [@Sneha6657](https://github.com/Sneha6657) | 1 | | sujeetkumar1425 | [@sujeetkumar1425](https://github.com/sujeetkumar1425) | 1 | @@ -160,6 +160,7 @@ We want to thank all the amazing contributors who have helped make TermUI what i | saam-07 | [@saam-07](https://github.com/saam-07) | 1 | | sripriya1156 | [@sripriya1156](https://github.com/sripriya1156) | 1 | | vidushi1129 | [@vidushi1129](https://github.com/vidushi1129) | 1 | +| Novice47 | [@Novice47](https://github.com/Novice47) | 1 | | Dev-aaditya | [@Dev-aaditya](https://github.com/Dev-aaditya) | 1 | | AbhishekAwasthi47 | [@AbhishekAwasthi47](https://github.com/AbhishekAwasthi47) | 1 | | A-adilajaleel | [@A-adilajaleel](https://github.com/A-adilajaleel) | 1 | @@ -172,6 +173,7 @@ We want to thank all the amazing contributors who have helped make TermUI what i | ravichandra14 | [@ravichandra14](https://github.com/ravichandra14) | 1 | | bhumindeshpande8-spec | [@bhumindeshpande8-spec](https://github.com/bhumindeshpande8-spec) | 1 | | CoderPrateek971 | [@CoderPrateek971](https://github.com/CoderPrateek971) | 1 | +| Dippp10-ally | [@Dippp10-ally](https://github.com/Dippp10-ally) | 1 | | DivyaShreeS09 | [@DivyaShreeS09](https://github.com/DivyaShreeS09) | 1 | | divyanshim27 | [@divyanshim27](https://github.com/divyanshim27) | 1 | | divyanshisrivastava395 | [@divyanshisrivastava395](https://github.com/divyanshisrivastava395) | 1 | @@ -188,4 +190,3 @@ We want to thank all the amazing contributors who have helped make TermUI what i | LalithMadhav-CODING | [@LalithMadhav-CODING](https://github.com/LalithMadhav-CODING) | 1 | | sahare77 | [@sahare77](https://github.com/sahare77) | 1 | | maheshshinde9100 | [@maheshshinde9100](https://github.com/maheshshinde9100) | 1 | -| manasvi-sahare | [@manasvi-sahare](https://github.com/manasvi-sahare) | 1 | From cd301420184f98aaf52f573175c43691c54e97a6 Mon Sep 17 00:00:00 2001 From: Mavis TermUI Bot Date: Mon, 3 Aug 2026 01:41:36 +0000 Subject: [PATCH 2/2] =?UTF-8?q?fix(data):=20address=20#3384=20=E2=80=94=20?= =?UTF-8?q?3384?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/create-termui-app/src/index.ts | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/packages/create-termui-app/src/index.ts b/packages/create-termui-app/src/index.ts index 1d921925a..799f7cf38 100644 --- a/packages/create-termui-app/src/index.ts +++ b/packages/create-termui-app/src/index.ts @@ -4,7 +4,7 @@ import { dirname, resolve, join } from 'node:path'; import { fileURLToPath } from 'node:url'; -import { mkdirSync, writeFileSync, existsSync, readFileSync } from 'node:fs'; +import { mkdirSync, writeFileSync, existsSync, readFileSync, readdirSync } from 'node:fs'; import { getBuiltinThemeNames } from '@termuijs/tss'; import { textPrompt, selectPrompt, multiSelectPrompt } from './prompts.js'; import { generateProject, type ProjectConfig } from './templates.js'; @@ -122,6 +122,17 @@ async function runProjectScaffold(args: CliArgs): Promise { // ── Generate project ── const projectDir = resolve(process.cwd(), projectName); if (existsSync(projectDir)) { + try { + const entries = fs.readdirSync(projectDir); + const hasContent = entries.some(e => e !== '.git'); + if (hasContent) { + console.log(`\n ✖ Directory "${projectName}" is not empty. Refusing to overwrite.\n`); + console.log(` Remove the directory or choose a different name.\n`); + return; + } + } catch { + // readdirSync failed — let the write calls fail naturally + } console.log(`\n ⚠ Directory "${projectName}" already exists. Files may be overwritten.\n`); }