@vercel/build-utils 2.12.3-canary.11 → 2.12.3-canary.15
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/dist/convert-runtime-to-plugin.d.ts +12 -0
- package/dist/convert-runtime-to-plugin.js +108 -0
- package/dist/fs/glob.js +2 -1
- package/dist/fs/normalize-path.d.ts +4 -0
- package/dist/fs/normalize-path.js +11 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1091 -828
- package/dist/lambda.d.ts +1 -0
- package/dist/lambda.js +6 -2
- package/dist/types.d.ts +1 -0
- package/package.json +5 -5
package/dist/lambda.d.ts
CHANGED
package/dist/lambda.js
CHANGED
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
4
4
|
};
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
6
|
-
exports.getLambdaOptionsFromFunction = exports.createZip = exports.createLambda = exports.Lambda = void 0;
|
6
|
+
exports.getLambdaOptionsFromFunction = exports.createZip = exports.createLambda = exports.Lambda = exports.FILES_SYMBOL = void 0;
|
7
7
|
const assert_1 = __importDefault(require("assert"));
|
8
8
|
const async_sema_1 = __importDefault(require("async-sema"));
|
9
9
|
const yazl_1 = require("yazl");
|
@@ -11,6 +11,7 @@ const minimatch_1 = __importDefault(require("minimatch"));
|
|
11
11
|
const fs_extra_1 = require("fs-extra");
|
12
12
|
const download_1 = require("./fs/download");
|
13
13
|
const stream_to_buffer_1 = __importDefault(require("./fs/stream-to-buffer"));
|
14
|
+
exports.FILES_SYMBOL = Symbol('files');
|
14
15
|
class Lambda {
|
15
16
|
constructor({ zipBuffer, handler, runtime, maxDuration, memory, environment, allowQuery, regions, }) {
|
16
17
|
this.type = 'Lambda';
|
@@ -49,7 +50,7 @@ async function createLambda({ files, handler, runtime, memory, maxDuration, envi
|
|
49
50
|
await sema.acquire();
|
50
51
|
try {
|
51
52
|
const zipBuffer = await createZip(files);
|
52
|
-
|
53
|
+
const lambda = new Lambda({
|
53
54
|
zipBuffer,
|
54
55
|
handler,
|
55
56
|
runtime,
|
@@ -58,6 +59,9 @@ async function createLambda({ files, handler, runtime, memory, maxDuration, envi
|
|
58
59
|
environment,
|
59
60
|
regions,
|
60
61
|
});
|
62
|
+
// @ts-ignore This symbol is a private API
|
63
|
+
lambda[exports.FILES_SYMBOL] = files;
|
64
|
+
return lambda;
|
61
65
|
}
|
62
66
|
finally {
|
63
67
|
sema.release();
|
package/dist/types.d.ts
CHANGED
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@vercel/build-utils",
|
3
|
-
"version": "2.12.3-canary.
|
3
|
+
"version": "2.12.3-canary.15",
|
4
4
|
"license": "MIT",
|
5
5
|
"main": "./dist/index.js",
|
6
6
|
"types": "./dist/index.d.js",
|
@@ -21,7 +21,7 @@
|
|
21
21
|
"@types/async-retry": "^1.2.1",
|
22
22
|
"@types/cross-spawn": "6.0.0",
|
23
23
|
"@types/end-of-stream": "^1.4.0",
|
24
|
-
"@types/fs-extra": "
|
24
|
+
"@types/fs-extra": "9.0.13",
|
25
25
|
"@types/glob": "^7.1.1",
|
26
26
|
"@types/jest": "27.0.1",
|
27
27
|
"@types/js-yaml": "3.12.1",
|
@@ -30,7 +30,7 @@
|
|
30
30
|
"@types/node-fetch": "^2.1.6",
|
31
31
|
"@types/semver": "6.0.0",
|
32
32
|
"@types/yazl": "^2.4.1",
|
33
|
-
"@vercel/frameworks": "0.5.1-canary.
|
33
|
+
"@vercel/frameworks": "0.5.1-canary.10",
|
34
34
|
"@vercel/ncc": "0.24.0",
|
35
35
|
"aggregate-error": "3.0.1",
|
36
36
|
"async-retry": "1.2.3",
|
@@ -38,7 +38,7 @@
|
|
38
38
|
"boxen": "4.2.0",
|
39
39
|
"cross-spawn": "6.0.5",
|
40
40
|
"end-of-stream": "1.4.1",
|
41
|
-
"fs-extra": "
|
41
|
+
"fs-extra": "10.0.0",
|
42
42
|
"glob": "7.1.3",
|
43
43
|
"into-stream": "5.0.0",
|
44
44
|
"js-yaml": "3.13.1",
|
@@ -49,5 +49,5 @@
|
|
49
49
|
"typescript": "4.3.4",
|
50
50
|
"yazl": "2.4.3"
|
51
51
|
},
|
52
|
-
"gitHead": "
|
52
|
+
"gitHead": "a6ccf6c180c88f0d606a2fd932bbf558ab78ddeb"
|
53
53
|
}
|