🚨 Latest Research:Tanstack npm Packages Compromised in Ongoing Mini Shai-Hulud Supply-Chain Attack.Learn More
Socket
Book a DemoSign in
Socket

@vercel/build-utils

Package Overview
Dependencies
Maintainers
2
Versions
427
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@vercel/build-utils - npm Package Compare versions

Comparing version
13.16.0
to
13.17.0
+13
dist/service-path-utils.d.ts
/**
* Shared utilities for generating internal service paths.
*
* These are used by builders (e.g. @vercel/python) to produce cron entries
* and rewrite routes for service builds.
*/
/**
* Reserved internal namespace used by services routing/runtime plumbing.
*/
export declare const INTERNAL_SERVICE_PREFIX = "/_svc";
export declare function getInternalServiceFunctionPath(serviceName: string): string;
export declare function getInternalServiceCronPathPrefix(serviceName: string): string;
export declare function getInternalServiceCronPath(serviceName: string, entrypoint: string, handler?: string): string;
"use strict";
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __export = (target, all) => {
for (var name in all)
__defProp(target, name, { get: all[name], enumerable: true });
};
var __copyProps = (to, from, except, desc) => {
if (from && typeof from === "object" || typeof from === "function") {
for (let key of __getOwnPropNames(from))
if (!__hasOwnProp.call(to, key) && key !== except)
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
}
return to;
};
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
var service_path_utils_exports = {};
__export(service_path_utils_exports, {
INTERNAL_SERVICE_PREFIX: () => INTERNAL_SERVICE_PREFIX,
getInternalServiceCronPath: () => getInternalServiceCronPath,
getInternalServiceCronPathPrefix: () => getInternalServiceCronPathPrefix,
getInternalServiceFunctionPath: () => getInternalServiceFunctionPath
});
module.exports = __toCommonJS(service_path_utils_exports);
const INTERNAL_SERVICE_PREFIX = "/_svc";
function normalizeInternalServiceEntrypoint(entrypoint) {
const normalized = entrypoint.replace(/\\/g, "/").replace(/^\/+/, "").replace(/\.[^/.]+$/, "");
return normalized || "index";
}
function getInternalServiceFunctionPath(serviceName) {
return `${INTERNAL_SERVICE_PREFIX}/${serviceName}/index`;
}
function getInternalServiceCronPathPrefix(serviceName) {
return `${INTERNAL_SERVICE_PREFIX}/${serviceName}/crons`;
}
function getInternalServiceCronPath(serviceName, entrypoint, handler = "cron") {
const normalizedEntrypoint = normalizeInternalServiceEntrypoint(entrypoint);
return `${getInternalServiceCronPathPrefix(serviceName)}/${normalizedEntrypoint}/${handler}`;
}
// Annotate the CommonJS export names for ESM import in node:
0 && (module.exports = {
INTERNAL_SERVICE_PREFIX,
getInternalServiceCronPath,
getInternalServiceCronPathPrefix,
getInternalServiceFunctionPath
});
+6
-0
# @vercel/build-utils
## 13.17.0
### Minor Changes
- Support dynamically specifying crons from a python service ([#15930](https://github.com/vercel/vercel/pull/15930))
## 13.16.0

@@ -4,0 +10,0 @@

+1
-0

@@ -40,2 +40,3 @@ import FileBlob from './file-blob';

export * from './node-entrypoint';
export * from './service-path-utils';
export { getEncryptedEnv, type EncryptedEnvFile, } from './process-serverless/get-encrypted-env-file';

@@ -42,0 +43,0 @@ export { getLambdaEnvironment } from './process-serverless/get-lambda-environment';

@@ -121,2 +121,4 @@ /// <reference types="node" />

workspace?: string;
/** Cron schedule expression (e.g., "0 0 * * *"). Only present for cron services. */
schedule?: string;
};

@@ -223,2 +225,7 @@ }

shutdown?: () => Promise<void>;
/**
* Cron entries produced by the builder for this service.
* Used by the dev orchestrator to schedule cron triggers.
*/
crons?: Cron[];
}

@@ -550,2 +557,3 @@ /**

deploymentId?: string;
crons?: Cron[];
}

@@ -563,2 +571,3 @@ export type BuildResultVX = {

output: Lambda | EdgeFunction;
crons?: Cron[];
}

@@ -565,0 +574,0 @@ export type BuildVX = (options: BuildOptions) => Promise<BuildResultVX>;

+1
-1
{
"name": "@vercel/build-utils",
"version": "13.16.0",
"version": "13.17.0",
"license": "Apache-2.0",

@@ -5,0 +5,0 @@ "main": "./dist/index.js",

Sorry, the diff of this file is too big to display