Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/firebase_studio/migrate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@

interface Metadata {
projectId?: string;
[key: string]: any;

Check warning on line 115 in src/firebase_studio/migrate.ts

View workflow job for this annotation

GitHub Actions / lint (20)

Unexpected any. Specify a different type
}

type AppType = "NEXT_JS" | "FLUTTER" | "ANGULAR" | "OTHER";
Expand All @@ -138,13 +138,13 @@
try {
const packageJsonPath = path.join(rootPath, "package.json");
const packageJsonContent = await fs.readFile(packageJsonPath, "utf8");
const packageJson = JSON.parse(packageJsonContent);

Check warning on line 141 in src/firebase_studio/migrate.ts

View workflow job for this annotation

GitHub Actions / lint (20)

Unsafe assignment of an `any` value
const deps = { ...packageJson.dependencies, ...packageJson.devDependencies };

Check warning on line 142 in src/firebase_studio/migrate.ts

View workflow job for this annotation

GitHub Actions / lint (20)

Unsafe member access .devDependencies on an `any` value

Check warning on line 142 in src/firebase_studio/migrate.ts

View workflow job for this annotation

GitHub Actions / lint (20)

Unsafe member access .dependencies on an `any` value

Check warning on line 142 in src/firebase_studio/migrate.ts

View workflow job for this annotation

GitHub Actions / lint (20)

Unsafe assignment of an `any` value

if (deps.next) {

Check warning on line 144 in src/firebase_studio/migrate.ts

View workflow job for this annotation

GitHub Actions / lint (20)

Unsafe member access .next on an `any` value
return "NEXT_JS";
}
if (deps["@angular/core"]) {

Check warning on line 147 in src/firebase_studio/migrate.ts

View workflow job for this annotation

GitHub Actions / lint (20)

Unsafe member access ["@angular/core"] on an `any` value
return "ANGULAR";
}
} catch {
Expand Down Expand Up @@ -174,7 +174,7 @@
return projectIdRegex.test(projectId);
};

export async function extractMetadata(

Check warning on line 177 in src/firebase_studio/migrate.ts

View workflow job for this annotation

GitHub Actions / lint (20)

Missing JSDoc comment
rootPath: string,
overrideProjectId?: string,
): Promise<{
Expand All @@ -192,11 +192,11 @@
metadata = JSON.parse(metadataContent) as Metadata;
logger.info(`✅ Read ${metadataFile}`);
} catch (err: unknown) {
logger.debug(`Could not read metadata at ${metadataFile}: ${err}`);

Check warning on line 195 in src/firebase_studio/migrate.ts

View workflow job for this annotation

GitHub Actions / lint (20)

Invalid type "unknown" of template literal expression
}
}

logger.debug(`overrideProjectId ${overrideProjectId}`);

Check warning on line 199 in src/firebase_studio/migrate.ts

View workflow job for this annotation

GitHub Actions / lint (20)

Invalid type "string | undefined" of template literal expression
logger.debug(`metadata.projectId ${metadata.projectId}`);
let projectId = overrideProjectId || metadata.projectId;
if (!projectId) {
Expand Down Expand Up @@ -796,6 +796,7 @@
void track.trackGA4("firebase_studio_migrate", { app_type: appType, result: "started" });

logger.info("🚀 Starting Firebase Studio to Antigravity migration...");
logger.info("\nFile any bugs at https://github.com/firebase/firebase-tools/issues");
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

This message is already displayed at the end of the migration process within the askToOpenAntigravity function (see line 749). Displaying it here at the start is redundant and should be removed to avoid duplicate messages in the command's output.


const { projectId, appName } = await extractMetadata(rootPath, options.project);

Expand Down
2 changes: 2 additions & 0 deletions templates/firebase-studio-export/readme_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,6 @@ Antigravity is our next-generation, agent-first IDE designed for high-velocity,

Enjoy the next era of AI-driven development!

File any bugs at https://github.com/firebase/firebase-tools/issues

**Firebase Studio Export Date:** ${exportDate}
Loading