firebase-tools-with-isolate 15.27.0 → 15.28.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.
- package/lib/commands/ext-export.js +85 -20
- package/lib/commands/ext-uninstall.js +35 -1
- package/lib/commands/functions-delete.js +19 -5
- package/lib/commands/functions-kits-install.js +228 -105
- package/lib/commands/functions-kits-list.js +27 -0
- package/lib/commands/index.js +1 -0
- package/lib/dataconnect/client.js +11 -0
- package/lib/dataconnect/schemaMigration.js +16 -5
- package/lib/deploy/extensions/secrets.js +18 -0
- package/lib/deploy/functions/functionsDeployHelper.js +39 -15
- package/lib/deploy/functions/prepare.js +43 -9
- package/lib/deploy/functions/runtimes/dart/features.js +51 -0
- package/lib/deploy/functions/runtimes/dart/index.js +60 -16
- package/lib/emulator/downloadableEmulatorInfo.json +31 -31
- package/lib/emulator/functionsEmulator.js +4 -1
- package/lib/experiments.js +6 -0
- package/lib/extensions/export.js +26 -0
- package/lib/extensions/replacementRegistry.js +30 -0
- package/lib/extensions/replacements.json +464 -0
- package/lib/fetchMOTD.js +3 -0
- package/lib/functions/env.js +11 -0
- package/lib/functions/iac/export.js +16 -1
- package/lib/functions/kits/config.js +8 -0
- package/lib/gcp/secretManager.js +3 -3
- package/lib/init/features/functions/dart.js +1 -1
- package/lib/mcp/tools/core/deploy.js +2 -0
- package/lib/mcp/tools/core/login.js +59 -4
- package/lib/mcp/tools/dataconnect/compile.js +23 -2
- package/lib/mcp/tools/dataconnect/list_services.js +3 -4
- package/lib/tsconfig.publish.tsbuildinfo +1 -1
- package/lib/unzip.js +12 -2
- package/package.json +2 -1
- package/templates/init/functions/dart/_gitignore +1 -0
- package/templates/init/functions/typescript/index.ts +3 -3
- package/templates/init/functions/typescript/package-ongraphrequest.lint.json +3 -3
- package/templates/init/functions/typescript/package.lint.json +3 -3
- package/templates/init/functions/typescript/tsconfig.dev.json +4 -0
package/lib/unzip.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.createUnzipTransform = exports.unzip = void 0;
|
|
4
|
+
exports.isChildDir = isChildDir;
|
|
4
5
|
const fs = require("fs");
|
|
5
6
|
const path = require("path");
|
|
6
7
|
const zlib = require("zlib");
|
|
@@ -66,7 +67,7 @@ const extractEntriesFromBuffer = async (data, outputDir) => {
|
|
|
66
67
|
await fs.promises.mkdir(outputFilePath, { recursive: true });
|
|
67
68
|
}
|
|
68
69
|
else {
|
|
69
|
-
const parentDir =
|
|
70
|
+
const parentDir = path.dirname(outputFilePath);
|
|
70
71
|
logger_1.logger.debug(`[unzip] else mkdir: ${parentDir}`);
|
|
71
72
|
await fs.promises.mkdir(parentDir, { recursive: true });
|
|
72
73
|
const compressionMethod = entryHeader.readUInt16LE(8);
|
|
@@ -89,7 +90,16 @@ function isChildDir(parentDir, potentialChild) {
|
|
|
89
90
|
try {
|
|
90
91
|
const resolvedParent = path.resolve(parentDir);
|
|
91
92
|
const resolvedChild = path.resolve(potentialChild);
|
|
92
|
-
|
|
93
|
+
if (process.platform === "win32") {
|
|
94
|
+
const lowerParent = resolvedParent.toLowerCase();
|
|
95
|
+
const lowerChild = resolvedChild.toLowerCase();
|
|
96
|
+
const parentWithSep = lowerParent.endsWith(path.sep) ? lowerParent : lowerParent + path.sep;
|
|
97
|
+
return lowerChild.startsWith(parentWithSep) && lowerChild !== lowerParent;
|
|
98
|
+
}
|
|
99
|
+
const parentWithSep = resolvedParent.endsWith(path.sep)
|
|
100
|
+
? resolvedParent
|
|
101
|
+
: resolvedParent + path.sep;
|
|
102
|
+
return resolvedChild.startsWith(parentWithSep) && resolvedChild !== resolvedParent;
|
|
93
103
|
}
|
|
94
104
|
catch (error) {
|
|
95
105
|
return false;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "firebase-tools-with-isolate",
|
|
3
|
-
"version": "15.
|
|
3
|
+
"version": "15.28.1",
|
|
4
4
|
"description": "Command-Line Interface for Firebase with monorepo support",
|
|
5
5
|
"main": "./lib/index.js",
|
|
6
6
|
"mcpName": "io.github.firebase/firebase-mcp",
|
|
@@ -19,6 +19,7 @@
|
|
|
19
19
|
"format:ts": "npm run lint:ts -- --fix --quiet",
|
|
20
20
|
"generate:auth-api": "ts-node scripts/gen-auth-api-spec.ts",
|
|
21
21
|
"generate:json-schema": "typescript-json-schema --strictNullChecks --required --noExtraProps --ignoreErrors src/firebaseConfig.ts FirebaseConfig > schema/firebase-config.json",
|
|
22
|
+
"scrape:extensions": "ts-node scripts/extensions-scraper/run-live-scan.ts",
|
|
22
23
|
"lint": "npm run lint:ts && npm run lint:other",
|
|
23
24
|
"lint:changed-files": "ts-node ./scripts/lint-changed-files.ts",
|
|
24
25
|
"lint:other": "prettier --check '**/*.{md,yaml,yml}'",
|
|
@@ -8,8 +8,8 @@
|
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
import {setGlobalOptions} from "firebase-functions";
|
|
11
|
-
import {onRequest} from "firebase-functions/https";
|
|
12
|
-
import * as logger from "firebase-functions/logger";
|
|
11
|
+
// import {onRequest} from "firebase-functions/https";
|
|
12
|
+
// import * as logger from "firebase-functions/logger";
|
|
13
13
|
|
|
14
14
|
// Start writing functions
|
|
15
15
|
// https://firebase.google.com/docs/functions/typescript
|
|
@@ -24,7 +24,7 @@ import * as logger from "firebase-functions/logger";
|
|
|
24
24
|
// functions should each use functions.runWith({ maxInstances: 10 }) instead.
|
|
25
25
|
// In the v1 API, each function can only serve one request per container, so
|
|
26
26
|
// this will be the maximum concurrent request count.
|
|
27
|
-
setGlobalOptions({
|
|
27
|
+
setGlobalOptions({maxInstances: 10});
|
|
28
28
|
|
|
29
29
|
// export const helloWorld = onRequest((request, response) => {
|
|
30
30
|
// logger.info("Hello logs!", {structuredData: true});
|
|
@@ -21,9 +21,9 @@
|
|
|
21
21
|
"@as-integrations/express4": "^1.1.2"
|
|
22
22
|
},
|
|
23
23
|
"devDependencies": {
|
|
24
|
-
"@typescript-eslint/eslint-plugin": "^
|
|
25
|
-
"@typescript-eslint/parser": "^
|
|
26
|
-
"eslint": "^8.
|
|
24
|
+
"@typescript-eslint/eslint-plugin": "^8.0.0",
|
|
25
|
+
"@typescript-eslint/parser": "^8.0.0",
|
|
26
|
+
"eslint": "^8.57.0",
|
|
27
27
|
"eslint-config-google": "^0.14.0",
|
|
28
28
|
"eslint-plugin-import": "^2.25.4",
|
|
29
29
|
"firebase-functions-test": "^3.4.1",
|
|
@@ -19,9 +19,9 @@
|
|
|
19
19
|
"firebase-functions": "^7.0.0"
|
|
20
20
|
},
|
|
21
21
|
"devDependencies": {
|
|
22
|
-
"@typescript-eslint/eslint-plugin": "^
|
|
23
|
-
"@typescript-eslint/parser": "^
|
|
24
|
-
"eslint": "^8.
|
|
22
|
+
"@typescript-eslint/eslint-plugin": "^8.0.0",
|
|
23
|
+
"@typescript-eslint/parser": "^8.0.0",
|
|
24
|
+
"eslint": "^8.57.0",
|
|
25
25
|
"eslint-config-google": "^0.14.0",
|
|
26
26
|
"eslint-plugin-import": "^2.25.4",
|
|
27
27
|
"firebase-functions-test": "^3.4.1",
|