0
Fork 0
mirror of https://github.com/withastro/astro.git synced 2025-02-17 22:44:24 -05:00

Revert "Provide better ignores for Vercel's file tracer (#9885)" (#9955)

* Revert "Provide better ignores for Vercel's file tracer (#9885)"

This reverts commit 49e0c24d7f.

* Changeset
This commit is contained in:
Matthew Phillips 2024-02-02 15:43:30 -05:00 committed by GitHub
parent 6c894af5ab
commit bc1742df94
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 6 additions and 20 deletions

View file

@ -0,0 +1,5 @@
---
"@astrojs/vercel": patch
---
Fix regression with bundling of @libsql/client

View file

@ -55,7 +55,6 @@
"@vercel/nft": "^0.24.3",
"esbuild": "^0.19.6",
"fast-glob": "^3.3.2",
"minimatch": "^9.0.3",
"set-cookie-parser": "^2.6.0",
"web-vitals": "^3.4.0"
},

View file

@ -2,14 +2,6 @@ import type { AstroIntegrationLogger } from 'astro';
import { relative, relative as relativePath } from 'node:path';
import { fileURLToPath } from 'node:url';
import { copyFilesToFunction } from './fs.js';
import { Minimatch } from 'minimatch';
const matchers = [
// Never venture into OS folders
'/dev/**',
// libsql contains many native deps that are false-positives.
'**/@libsql/client/**/*',
].map((pattern) => new Minimatch(pattern, { dot: true }));
export async function copyDependenciesToFunction(
{
@ -46,14 +38,7 @@ export async function copyDependenciesToFunction(
base: fileURLToPath(base),
// If you have a route of /dev this appears in source and NFT will try to
// scan your local /dev :8
ignore(path) {
for (const minimatch of matchers) {
if (minimatch.match(path)) {
return true;
}
}
return false;
},
ignore: ['/dev/**'],
cache,
});

3
pnpm-lock.yaml generated
View file

@ -4708,9 +4708,6 @@ importers:
fast-glob:
specifier: ^3.3.2
version: 3.3.2
minimatch:
specifier: ^9.0.3
version: 9.0.3
set-cookie-parser:
specifier: ^2.6.0
version: 2.6.0