@vercel/client 17.2.4 → 17.2.5
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/utils/index.js +13 -3
- package/package.json +1 -1
package/dist/utils/index.js
CHANGED
|
@@ -121,8 +121,8 @@ async function buildFileTree(path, {
|
|
|
121
121
|
return ignored;
|
|
122
122
|
};
|
|
123
123
|
fileList = await (0, import_readdir_recursive.default)(path, [ignores2]);
|
|
124
|
+
const refs = /* @__PURE__ */ new Set();
|
|
124
125
|
if (prebuilt) {
|
|
125
|
-
const refs = /* @__PURE__ */ new Set();
|
|
126
126
|
const vcConfigFilePaths = fileList.filter(
|
|
127
127
|
(file) => (0, import_path.basename)(file) === ".vc-config.json"
|
|
128
128
|
);
|
|
@@ -155,9 +155,19 @@ async function buildFileTree(path, {
|
|
|
155
155
|
} catch (e) {
|
|
156
156
|
debug(`Error detecting microfrontend config: ${e}`);
|
|
157
157
|
}
|
|
158
|
-
|
|
159
|
-
|
|
158
|
+
}
|
|
159
|
+
try {
|
|
160
|
+
const routesJsonPath = (0, import_path.join)(path, ".vercel", "routes.json");
|
|
161
|
+
const routesJsonContent = await maybeRead(routesJsonPath, null);
|
|
162
|
+
if (routesJsonContent !== null) {
|
|
163
|
+
refs.add(routesJsonPath);
|
|
164
|
+
debug("Including .vercel/routes.json in deployment");
|
|
160
165
|
}
|
|
166
|
+
} catch (e) {
|
|
167
|
+
debug(`Error checking for .vercel/routes.json: ${e}`);
|
|
168
|
+
}
|
|
169
|
+
if (refs.size > 0) {
|
|
170
|
+
fileList = fileList.concat(Array.from(refs));
|
|
161
171
|
}
|
|
162
172
|
debug(`Found ${fileList.length} files in the specified directory`);
|
|
163
173
|
} else if (Array.isArray(path)) {
|