create-nextblock 0.2.18 → 0.2.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/create-nextblock.js +9 -6
- package/package.json +1 -1
package/bin/create-nextblock.js
CHANGED
|
@@ -191,6 +191,15 @@ async function runSetupWizard(projectDir, projectName) {
|
|
|
191
191
|
|
|
192
192
|
clack.note('Now, please select your NextBlock project when prompted.');
|
|
193
193
|
await execa('npx', ['supabase', 'link'], { cwd: projectPath, stdio: 'inherit' });
|
|
194
|
+
if (process.stdin.isTTY) {
|
|
195
|
+
try {
|
|
196
|
+
process.stdin.setRawMode(false);
|
|
197
|
+
} catch (_) {
|
|
198
|
+
// ignore
|
|
199
|
+
}
|
|
200
|
+
process.stdin.setEncoding('utf8');
|
|
201
|
+
process.stdin.resume();
|
|
202
|
+
}
|
|
194
203
|
|
|
195
204
|
// Ensure supabase assets exist (config + migrations) after link in case the CLI created/overrode files
|
|
196
205
|
await ensureSupabaseAssets(projectPath);
|
|
@@ -675,12 +684,6 @@ async function ensureSupabaseAssets(projectDir) {
|
|
|
675
684
|
clack.note('Warning: No supabase assets found in installed packages.');
|
|
676
685
|
}
|
|
677
686
|
for (const sourceSupabaseDir of sources) {
|
|
678
|
-
const sourceConfig = resolve(sourceSupabaseDir, 'config.toml');
|
|
679
|
-
const destConfig = resolve(destSupabaseDir, 'config.toml');
|
|
680
|
-
if ((await fs.pathExists(sourceConfig)) && !(await fs.pathExists(destConfig))) {
|
|
681
|
-
await fs.copy(sourceConfig, destConfig, { overwrite: false });
|
|
682
|
-
}
|
|
683
|
-
|
|
684
687
|
const sourceMigrations = resolve(sourceSupabaseDir, 'migrations');
|
|
685
688
|
const destMigrations = resolve(destSupabaseDir, 'migrations');
|
|
686
689
|
if (await fs.pathExists(sourceMigrations)) {
|