forge-remote 0.1.7 → 0.1.8

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/package.json +1 -1
  2. package/src/init.js +19 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "forge-remote",
3
- "version": "0.1.7",
3
+ "version": "0.1.8",
4
4
  "description": "Desktop relay for Forge Remote — monitor and control Claude Code sessions from your phone",
5
5
  "type": "module",
6
6
  "license": "UNLICENSED",
package/src/init.js CHANGED
@@ -548,7 +548,25 @@ export async function runInit({ projectId: overrideProjectId } = {}) {
548
548
 
549
549
  console.log(chalk.bold("\nšŸ“‹ Step 5/11 — Enabling Firestore...\n"));
550
550
 
551
- // First check if Firestore already exists by listing databases.
551
+ // Enable the Firestore API first (required for new projects).
552
+ try {
553
+ console.log(
554
+ chalk.dim(" Enabling Firestore API (if not already enabled)..."),
555
+ );
556
+ await enableApi(projectId, "firestore.googleapis.com");
557
+ console.log(chalk.green(" āœ“ Firestore API enabled"));
558
+ } catch (e) {
559
+ console.log(
560
+ chalk.yellow(` ⚠ Could not enable Firestore API: ${e.message}`),
561
+ );
562
+ console.log(
563
+ chalk.dim(
564
+ " Continuing — Firestore creation may still work if already enabled.",
565
+ ),
566
+ );
567
+ }
568
+
569
+ // Check if Firestore already exists by listing databases.
552
570
  const existingDbs = run(
553
571
  ["firebase", "firestore:databases:list", "--project", projectId],
554
572
  { silent: true },