@vercel/static-build 1.0.14 → 1.0.17

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 (2) hide show
  1. package/dist/index.js +6 -15
  2. package/package.json +6 -7
package/dist/index.js CHANGED
@@ -18973,21 +18973,12 @@ const build = async ({ files, entrypoint, workPath, config, meta = {}, }) => {
18973
18973
  }
18974
18974
  if (framework) {
18975
18975
  build_utils_1.debug(`Detected ${framework.name} framework. Optimizing your deployment...`);
18976
- if (process.env.VERCEL_URL) {
18977
- const vercelSystemEnvPrefix = 'VERCEL_';
18978
- const { envPrefix } = framework;
18979
- if (envPrefix) {
18980
- Object.keys(process.env)
18981
- .filter(key => key.startsWith(vercelSystemEnvPrefix))
18982
- .forEach(key => {
18983
- const newKey = `${envPrefix}${key}`;
18984
- if (!(newKey in process.env)) {
18985
- process.env[newKey] = process.env[key];
18986
- }
18987
- });
18988
- // tell turbo to exclude all vercel system env vars (envPrefix includes trailing underscore)
18989
- process.env.TURBO_CI_VENDOR_ENV_KEY = `${envPrefix}${vercelSystemEnvPrefix}`;
18990
- }
18976
+ const prefixedEnvs = build_utils_1.getPrefixedEnvVars({
18977
+ envPrefix: framework.envPrefix,
18978
+ envs: process.env,
18979
+ });
18980
+ for (const [key, value] of Object.entries(prefixedEnvs)) {
18981
+ process.env[key] = value;
18991
18982
  }
18992
18983
  if (process.env.VERCEL_ANALYTICS_ID) {
18993
18984
  const frameworkDirectory = path_1.default.join(workPath, path_1.default.dirname(entrypoint));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vercel/static-build",
3
- "version": "1.0.14",
3
+ "version": "1.0.17",
4
4
  "license": "MIT",
5
5
  "main": "./dist/index",
6
6
  "homepage": "https://vercel.com/docs/build-step",
@@ -16,8 +16,7 @@
16
16
  "build": "node build",
17
17
  "test": "jest --env node --verbose --bail --runInBand",
18
18
  "test-unit": "yarn test test/build.test.ts test/prepare-cache.test.ts",
19
- "test-integration-once": "yarn test test/integration-*.test.js",
20
- "prepublishOnly": "node build"
19
+ "test-integration-once": "yarn test test/integration-*.test.js"
21
20
  },
22
21
  "jest": {
23
22
  "preset": "ts-jest/presets/default",
@@ -37,10 +36,10 @@
37
36
  "@types/ms": "0.7.31",
38
37
  "@types/node-fetch": "2.5.4",
39
38
  "@types/promise-timeout": "1.3.0",
40
- "@vercel/build-utils": "5.1.0",
41
- "@vercel/frameworks": "1.1.1",
39
+ "@vercel/build-utils": "5.3.0",
40
+ "@vercel/frameworks": "1.1.3",
42
41
  "@vercel/ncc": "0.24.0",
43
- "@vercel/routing-utils": "2.0.0",
42
+ "@vercel/routing-utils": "2.0.2",
44
43
  "fs-extra": "10.0.0",
45
44
  "get-port": "5.0.0",
46
45
  "is-port-reachable": "2.0.1",
@@ -49,5 +48,5 @@
49
48
  "rc9": "1.2.0",
50
49
  "typescript": "4.3.4"
51
50
  },
52
- "gitHead": "7db6436797d0b4131113f0b8dccc3b66bc9b1981"
51
+ "gitHead": "47e3381c6df661168e8be335cc58df03f3cf2414"
53
52
  }