fleetbo-cockpit-cli 1.0.5 → 1.0.6

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.
Files changed (2) hide show
  1. package/cli.js +18 -0
  2. package/package.json +1 -1
package/cli.js CHANGED
@@ -348,6 +348,24 @@ else if (command === 'android' || command === 'ios') {
348
348
  console.log(`\x1b[90m ${nativeFileCount} native module(s) detected\x1b[0m\n`);
349
349
 
350
350
  try {
351
+ // ==========================================================
352
+ // 🟢 NOUVEAU : ÉTAPE 0 (PRE-FLIGHT CHECK QUOTAS)
353
+ // ==========================================================
354
+ process.stdout.write(`\x1b[33m[0/3]\x1b[0m Checking Propulsion Quotas... `);
355
+ try {
356
+ await axios.post(targetUrl, {}, {
357
+ headers: {
358
+ 'x-project-id': projectId,
359
+ 'x-preflight': 'true' // Signale au serveur de ne pas chercher de ZIP
360
+ }
361
+ });
362
+ process.stdout.write(`\x1b[32mOK\x1b[0m\n\n`);
363
+ } catch (preflightError) {
364
+ process.stdout.write(`\x1b[31mDENIED\x1b[0m\n`);
365
+ // Fait sauter le code directement au "catch" global du bas sans jamais builder
366
+ throw preflightError;
367
+ }
368
+
351
369
  // Étape 1: Build React
352
370
  console.log(`\x1b[33m[1/3]\x1b[0m Building React bundle...`);
353
371
  execSync('npm run build', { stdio: 'inherit' });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fleetbo-cockpit-cli",
3
- "version": "1.0.5",
3
+ "version": "1.0.6",
4
4
  "description": "Fleetbo CLI - Build native mobile apps with React",
5
5
  "author": "Fleetbo",
6
6
  "license": "MIT",