@vercel/build-utils
Advanced tools
+6
-0
| # @vercel/build-utils | ||
| ## 13.22.0 | ||
| ### Minor Changes | ||
| - e53dd86: Add service type to project manifest. | ||
| ## 13.21.0 | ||
@@ -4,0 +10,0 @@ |
@@ -15,2 +15,3 @@ import type { Diagnostics } from './types'; | ||
| framework?: string; | ||
| serviceType?: string; | ||
| runtimeVersion?: { | ||
@@ -17,0 +18,0 @@ requested?: string; |
@@ -147,2 +147,6 @@ export declare const functionsSchema: { | ||
| }; | ||
| readonly serviceType: { | ||
| readonly type: "string"; | ||
| readonly description: "Service type: one of \"web\", \"schedule\", \"queue\", \"workflow\"."; | ||
| }; | ||
| readonly runtimeVersion: { | ||
@@ -149,0 +153,0 @@ readonly type: "object"; |
+4
-0
@@ -194,2 +194,6 @@ "use strict"; | ||
| }, | ||
| serviceType: { | ||
| type: "string", | ||
| description: 'Service type: one of "web", "schedule", "queue", "workflow".' | ||
| }, | ||
| runtimeVersion: { | ||
@@ -196,0 +200,0 @@ type: "object", |
+5
-0
@@ -540,2 +540,7 @@ import type FileRef from './file-ref'; | ||
| }): boolean; | ||
| export type ReportedServiceType = 'web' | 'schedule' | 'queue' | 'workflow'; | ||
| export declare function getReportedServiceType(service: { | ||
| type?: ServiceType; | ||
| trigger?: JobTrigger; | ||
| }): ReportedServiceType | undefined; | ||
| /** The framework which created the function */ | ||
@@ -542,0 +547,0 @@ export interface FunctionFramework { |
+22
-0
@@ -25,2 +25,3 @@ "use strict"; | ||
| Version: () => Version, | ||
| getReportedServiceType: () => getReportedServiceType, | ||
| getServiceQueueTopicConfigs: () => getServiceQueueTopicConfigs, | ||
@@ -72,2 +73,22 @@ getServiceQueueTopics: () => getServiceQueueTopics, | ||
| } | ||
| function getReportedServiceType(service) { | ||
| switch (service.type) { | ||
| case "web": | ||
| return "web"; | ||
| case "cron": | ||
| return "schedule"; | ||
| case "worker": | ||
| return "queue"; | ||
| case "job": | ||
| if (service.trigger === "schedule") | ||
| return "schedule"; | ||
| if (service.trigger === "queue") | ||
| return "queue"; | ||
| if (service.trigger === "workflow") | ||
| return "workflow"; | ||
| return void 0; | ||
| default: | ||
| return void 0; | ||
| } | ||
| } | ||
| // Annotate the CommonJS export names for ESM import in node: | ||
@@ -79,2 +100,3 @@ 0 && (module.exports = { | ||
| Version, | ||
| getReportedServiceType, | ||
| getServiceQueueTopicConfigs, | ||
@@ -81,0 +103,0 @@ getServiceQueueTopics, |
+8
-10
| { | ||
| "name": "@vercel/build-utils", | ||
| "version": "13.21.0", | ||
| "version": "13.22.0", | ||
| "license": "Apache-2.0", | ||
@@ -19,4 +19,2 @@ "main": "./dist/index.js", | ||
| "devDependencies": { | ||
| "bytes": "3.1.2", | ||
| "smol-toml": "1.5.2", | ||
| "@types/async-retry": "^1.2.1", | ||
@@ -28,3 +26,2 @@ "@types/bytes": "3.1.1", | ||
| "@types/glob": "7.2.0", | ||
| "@types/jest": "27.4.1", | ||
| "@types/js-yaml": "3.12.1", | ||
@@ -42,2 +39,3 @@ "@types/mime-types": "2.1.0", | ||
| "async-sema": "2.1.4", | ||
| "bytes": "3.1.2", | ||
| "cross-spawn": "6.0.5", | ||
@@ -50,4 +48,4 @@ "end-of-stream": "1.4.1", | ||
| "into-stream": "5.0.0", | ||
| "jest-junit": "16.0.0", | ||
| "js-yaml": "3.13.1", | ||
| "json5": "2.2.3", | ||
| "mime-types": "2.1.28", | ||
@@ -59,11 +57,11 @@ "minimatch": "3.1.2", | ||
| "semver": "6.3.1", | ||
| "smol-toml": "1.5.2", | ||
| "vitest": "2.0.1", | ||
| "yazl": "2.5.1", | ||
| "vitest": "2.0.1", | ||
| "json5": "2.2.3", | ||
| "@vercel/error-utils": "2.1.0", | ||
| "@vercel/routing-utils": "6.2.0" | ||
| "@vercel/routing-utils": "6.2.0", | ||
| "@vercel/error-utils": "2.1.0" | ||
| }, | ||
| "scripts": { | ||
| "build": "node build.mjs", | ||
| "test": "jest --reporters=default --reporters=jest-junit --env node --verbose --bail --runInBand", | ||
| "test": "vitest run --config ../../vitest.config.mts", | ||
| "vitest-run": "vitest -c ../../vitest.config.mts", | ||
@@ -70,0 +68,0 @@ "vitest-unit": "glob --absolute 'test/unit.*test.ts'", |
Sorry, the diff of this file is too big to display
Network access
Supply chain riskThis module accesses the network.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 11 instances in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 3 instances in 1 package
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
Found 1 instance in 1 package
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
Found 1 instance in 1 package
Network access
Supply chain riskThis module accesses the network.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 11 instances in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 3 instances in 1 package
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
Found 1 instance in 1 package
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
Found 1 instance in 1 package
1754981
0.1%39
-4.88%43926
0.14%