firebase-tools 15.33.0 → 15.34.1

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 (74) hide show
  1. package/README.md +9 -0
  2. package/lib/apphosting/backend.js +1 -1
  3. package/lib/auth.js +10 -5
  4. package/lib/checkValidTargetFilters.js +1 -0
  5. package/lib/command.js +30 -23
  6. package/lib/commands/crashlytics-heapdumps-disable.js +26 -0
  7. package/lib/commands/crashlytics-heapdumps-enable.js +54 -0
  8. package/lib/commands/crashlytics-heapdumps-status.js +32 -0
  9. package/lib/commands/deploy.js +7 -0
  10. package/lib/commands/hosting-channel-create.js +3 -0
  11. package/lib/commands/hosting-channel-delete.js +3 -0
  12. package/lib/commands/hosting-channel-deploy.js +3 -0
  13. package/lib/commands/hosting-channel-list.js +3 -0
  14. package/lib/commands/hosting-channel-open.js +3 -0
  15. package/lib/commands/hosting-clone.js +63 -9
  16. package/lib/commands/hosting-disable.js +2 -0
  17. package/lib/commands/hosting-sites-create.js +3 -0
  18. package/lib/commands/hosting-sites-delete.js +3 -0
  19. package/lib/commands/hosting-sites-get.js +3 -0
  20. package/lib/commands/hosting-sites-list.js +3 -0
  21. package/lib/commands/index.js +9 -0
  22. package/lib/commands/init.js +7 -0
  23. package/lib/commands/run-services-update.js +18 -0
  24. package/lib/crashlytics/alerts.js +1 -11
  25. package/lib/crashlytics/onboarding.js +10 -5
  26. package/lib/crashlytics/profilingManager.js +195 -0
  27. package/lib/deploy/apphosting/prepare.js +1 -0
  28. package/lib/deploy/auth/deploy.js +1 -1
  29. package/lib/deploy/auth/prepare.js +6 -7
  30. package/lib/deploy/firestore/prepare.js +5 -5
  31. package/lib/deploy/functions/params.js +1 -0
  32. package/lib/deploy/functions/release/executor.js +7 -3
  33. package/lib/deploy/functions/release/fabricator.js +41 -9
  34. package/lib/deploy/functions/release/sourceTokenScraper.js +1 -1
  35. package/lib/deploy/hosting/prepare.js +3 -0
  36. package/lib/deploy/index.js +5 -0
  37. package/lib/deploy/run/args.js +2 -0
  38. package/lib/deploy/run/buildEnv.js +72 -0
  39. package/lib/deploy/run/deploy.js +242 -0
  40. package/lib/deploy/run/index.js +23 -0
  41. package/lib/deploy/run/prepare.js +99 -0
  42. package/lib/deploy/run/prereqs.js +32 -0
  43. package/lib/deploy/run/release.js +9 -0
  44. package/lib/deploy/run/update.js +51 -0
  45. package/lib/deploy/run/util.js +75 -0
  46. package/lib/emulator/apphosting/serve.js +1 -1
  47. package/lib/emulator/auth/cloudFunctions.js +47 -18
  48. package/lib/emulator/auth/utils.js +1 -1
  49. package/lib/emulator/commandUtils.js +7 -3
  50. package/lib/emulator/dataconnect/pgliteServer.js +1 -1
  51. package/lib/emulator/dataconnectEmulator.js +1 -1
  52. package/lib/emulator/download.js +1 -1
  53. package/lib/emulator/downloadableEmulatorInfo.json +31 -31
  54. package/lib/emulator/downloadableEmulators.js +1 -3
  55. package/lib/emulator/eventarcEmulator.js +1 -1
  56. package/lib/emulator/functionsEmulatorShared.js +1 -41
  57. package/lib/experiments.js +1 -17
  58. package/lib/firestore/validator.js +1 -1
  59. package/lib/functions/projectConfig.js +10 -5
  60. package/lib/gcp/cloudsql/permissions.js +21 -32
  61. package/lib/gcp/cloudsql/permissionsSetup.js +6 -6
  62. package/lib/gcp/storage.js +9 -5
  63. package/lib/init/features/index.js +4 -1
  64. package/lib/init/features/run.js +198 -0
  65. package/lib/init/index.js +6 -0
  66. package/lib/mcp/index.js +19 -3
  67. package/lib/profileReport.js +8 -5
  68. package/lib/throttler/throttler.js +1 -0
  69. package/lib/tsconfig.compile.tsbuildinfo +1 -1
  70. package/lib/tsconfig.publish.tsbuildinfo +1 -1
  71. package/package.json +8 -8
  72. package/schema/firebaserc.json +133 -0
  73. package/lib/mcp/resources/guides/init_data_connect.js +0 -30
  74. package/lib/mcp/resources/guides/init_rtdb.js +0 -30
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "firebase-tools",
3
- "version": "15.33.0",
3
+ "version": "15.34.1",
4
4
  "description": "Command-Line Interface for Firebase",
5
5
  "main": "./lib/index.js",
6
6
  "mcpName": "io.github.firebase/firebase-mcp",
@@ -63,7 +63,6 @@
63
63
  ]
64
64
  },
65
65
  "dependencies": {
66
- "@apphosting/common": "^0.0.8",
67
66
  "@electric-sql/pglite": "^0.3.3",
68
67
  "@electric-sql/pglite-tools": "^0.2.8",
69
68
  "@google-cloud/cloud-sql-connector": "^1.3.3",
@@ -114,7 +113,6 @@
114
113
  "pglite-2": "npm:@electric-sql/pglite@0.2.17",
115
114
  "portfinder": "^1.0.32",
116
115
  "progress": "^2.0.3",
117
- "proxy-agent": "^6.3.0",
118
116
  "retry": "^0.13.1",
119
117
  "semver": "^7.5.2",
120
118
  "sql-formatter": "^15.3.0",
@@ -126,7 +124,6 @@
126
124
  "tmp": "^0.2.3",
127
125
  "triple-beam": "^1.3.0",
128
126
  "undici": "^6.19.0",
129
- "universal-analytics": "^0.5.3",
130
127
  "update-notifier-cjs": "^5.1.6",
131
128
  "winston": "^3.0.0",
132
129
  "winston-transport": "^4.4.0",
@@ -152,12 +149,9 @@
152
149
  "qs": "^6.16.0",
153
150
  "tar": "^7.5.21",
154
151
  "@opentelemetry/core": "^2.8.0",
155
- "basic-ftp": "^5.3.1",
152
+ "basic-ftp": "^6.2.1",
156
153
  "re2": "1.24.0",
157
154
  "@babel/traverse": "^7.23.2",
158
- "universal-analytics": {
159
- "uuid": "^11.1.1"
160
- },
161
155
  "gaxios": {
162
156
  "uuid": "^11.1.1"
163
157
  },
@@ -170,5 +164,11 @@
170
164
  "@google-cloud/cloud-sql-connector": {
171
165
  "uuid": "^11.1.1"
172
166
  }
167
+ },
168
+ "allowScripts": {
169
+ "esbuild": true,
170
+ "protobufjs": false,
171
+ "puppeteer": false,
172
+ "re2": true
173
173
  }
174
174
  }
@@ -0,0 +1,133 @@
1
+ {
2
+ "$schema": "http://json-schema.org/draft-07/schema#",
3
+ "title": "Firebase Runtime Configuration",
4
+ "description": "Schema for the Firebase Runtime Configuration file (.firebaserc).",
5
+ "type": "object",
6
+ "additionalProperties": false,
7
+ "definitions": {
8
+ "projectTargets": {
9
+ "type": "object",
10
+ "description": "Resource target configurations for a specific Firebase project ID.",
11
+ "properties": {
12
+ "hosting": {
13
+ "type": "object",
14
+ "description": "Maps hosting target names (specified in firebase.json) to an array containing the Firebase Hosting site name.",
15
+ "additionalProperties": {
16
+ "type": "array",
17
+ "description": "Array of Firebase Hosting site name(s) associated with this target name.",
18
+ "items": {
19
+ "type": "string"
20
+ }
21
+ }
22
+ },
23
+ "storage": {
24
+ "type": "object",
25
+ "description": "Maps storage target names (specified in firebase.json) to an array of Cloud Storage bucket names.",
26
+ "additionalProperties": {
27
+ "type": "array",
28
+ "description": "Array of Cloud Storage bucket name(s) associated with this target name.",
29
+ "items": {
30
+ "type": "string"
31
+ }
32
+ }
33
+ },
34
+ "database": {
35
+ "type": "object",
36
+ "description": "Maps Realtime Database target names (specified in firebase.json) to an array of Realtime Database instance names.",
37
+ "additionalProperties": {
38
+ "type": "array",
39
+ "description": "Array of Realtime Database instance name(s) associated with this target name.",
40
+ "items": {
41
+ "type": "string"
42
+ }
43
+ }
44
+ },
45
+ "firestore": {
46
+ "type": "object",
47
+ "description": "Maps Firestore target names (specified in firebase.json) to an array of Firestore database IDs.",
48
+ "additionalProperties": {
49
+ "type": "array",
50
+ "description": "Array of Firestore database ID(s) associated with this target name.",
51
+ "items": {
52
+ "type": "string"
53
+ }
54
+ }
55
+ }
56
+ },
57
+ "additionalProperties": {
58
+ "type": "object",
59
+ "description": "Resource targets for additional target types, mapping target names to an array of resource identifiers.",
60
+ "additionalProperties": {
61
+ "type": "array",
62
+ "description": "Array of resource identifiers associated with this target name.",
63
+ "items": {
64
+ "type": "string"
65
+ }
66
+ }
67
+ }
68
+ },
69
+ "projectEtags": {
70
+ "type": "object",
71
+ "description": "ETags for resources within a specific Firebase project.",
72
+ "properties": {
73
+ "extensionInstances": {
74
+ "type": "object",
75
+ "description": "Maps deployed Firebase Extension instance IDs to their deployed ETag hash.",
76
+ "additionalProperties": {
77
+ "type": "string",
78
+ "description": "The ETag string returned by the Firebase Extensions API for this instance."
79
+ }
80
+ }
81
+ },
82
+ "additionalProperties": false
83
+ }
84
+ },
85
+ "properties": {
86
+ "projects": {
87
+ "type": "object",
88
+ "description": "Maps project aliases (such as 'default', 'staging', or 'production') to Firebase Project IDs.",
89
+ "properties": {
90
+ "default": {
91
+ "type": "string",
92
+ "description": "The default Firebase Project ID used when no project or alias is explicitly specified."
93
+ }
94
+ },
95
+ "additionalProperties": {
96
+ "type": "string",
97
+ "description": "The Firebase Project ID associated with this alias."
98
+ }
99
+ },
100
+ "targets": {
101
+ "type": "object",
102
+ "description": "Maps Firebase project IDs to named resource targets for multi-resource deployments.",
103
+ "additionalProperties": {
104
+ "$ref": "#/definitions/projectTargets"
105
+ }
106
+ },
107
+ "etags": {
108
+ "type": "object",
109
+ "description": "Stores resource ETags per project to detect drift and out-of-band updates during extension deployments.",
110
+ "additionalProperties": {
111
+ "$ref": "#/definitions/projectEtags"
112
+ }
113
+ },
114
+ "dataconnectEmulatorConfig": {
115
+ "type": "object",
116
+ "description": "Deprecated configuration for the Firebase Data Connect emulator.",
117
+ "properties": {
118
+ "postgres": {
119
+ "type": "object",
120
+ "description": "PostgreSQL database configuration for the emulator.",
121
+ "properties": {
122
+ "localConnectionString": {
123
+ "type": "string",
124
+ "description": "Connection string to a local PostgreSQL instance."
125
+ }
126
+ },
127
+ "additionalProperties": false
128
+ }
129
+ },
130
+ "additionalProperties": false
131
+ }
132
+ }
133
+ }
@@ -1,30 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.init_data_connect = void 0;
4
- const resource_1 = require("../../resource");
5
- exports.init_data_connect = (0, resource_1.resource)({
6
- uri: "firebase://guides/init/data_connect",
7
- name: "data_connect_init_guide",
8
- title: "Firebase SQL Connect Init Guide",
9
- description: "guides the coding agent through configuring SQL Connect for PostgreSQL access in the current project",
10
- }, async (uri) => {
11
- return {
12
- contents: [
13
- {
14
- uri,
15
- type: "text",
16
- text: `
17
- Create a file called \`data-connect.ts\`:
18
-
19
- \`\`\`ts
20
- import { initializeApp } from "firebase/app";
21
- import { getDataConnect } from "firebase/data-connect";
22
-
23
- const app = initializeApp({...});
24
- const db = getDataConnect(app);
25
- \`\`\`
26
- `.trim(),
27
- },
28
- ],
29
- };
30
- });
@@ -1,30 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.init_rtdb = void 0;
4
- const resource_1 = require("../../resource");
5
- exports.init_rtdb = (0, resource_1.resource)({
6
- uri: "firebase://guides/init/rtdb",
7
- name: "rtdb_init_guide",
8
- title: "Firebase Realtime Database Init Guide",
9
- description: "guides the coding agent through configuring Realtime Database in the current project",
10
- }, async (uri) => {
11
- return {
12
- contents: [
13
- {
14
- uri,
15
- type: "text",
16
- text: `
17
- Create a file called \`rtdb.ts\`:
18
-
19
- \`\`\`ts
20
- import { initializeApp } from "firebase/app";
21
- import { getDatabase } from "firebase/database";
22
-
23
- const app = initializeApp({...});
24
- const db = getDatabase(app);
25
- \`\`\`
26
- `.trim(),
27
- },
28
- ],
29
- };
30
- });