mirror of https://github.com/wg-easy/wg-easy
5 changed files with 35 additions and 5 deletions
@ -0,0 +1,23 @@ |
|||
diff --git a/dist/runtime/npm/debug.mjs b/dist/runtime/npm/debug.mjs
|
|||
index 62fa13e3a5e96ee835dfe7363e7451e987ef11bc..85b923f5f5597519486b5a11604af6dbfadb0a0d 100644
|
|||
--- a/dist/runtime/npm/debug.mjs
|
|||
+++ b/dist/runtime/npm/debug.mjs
|
|||
@@ -1,7 +1,17 @@
|
|||
function createDebug(namespace) { |
|||
return Object.assign((...args) => { |
|||
const env = globalThis.process?.env.DEBUG; |
|||
- if (!env || env !== "*" && !env.startsWith(namespace)) return;
|
|||
+ if (!env) return;
|
|||
+ if (env !== "*") {
|
|||
+ const patterns = env.split(",").map((n) => n.trim());
|
|||
+ const isMatch = patterns.some((pattern) => {
|
|||
+ if (pattern.endsWith("*")) {
|
|||
+ return namespace.startsWith(pattern.slice(0, -1));
|
|||
+ }
|
|||
+ return pattern === namespace;
|
|||
+ });
|
|||
+ if (!isMatch) return;
|
|||
+ }
|
|||
console.debug(...args); |
|||
}, { |
|||
color: "#000000", |
|||
@ -4,6 +4,9 @@ settings: |
|||
autoInstallPeers: true |
|||
excludeLinksFromLockfile: false |
|||
|
|||
patchedDependencies: |
|||
unenv: 0caa5c5d7b4e6f60d88785861150e490da5445d2c6f3b33d505962721162b87d |
|||
|
|||
importers: |
|||
|
|||
.: |
|||
@ -7739,7 +7742,7 @@ snapshots: |
|||
seroval: 1.5.4 |
|||
std-env: 4.1.0 |
|||
ufo: 1.6.4 |
|||
unenv: 2.0.0-rc.24 |
|||
unenv: 2.0.0-rc.24(patch_hash=0caa5c5d7b4e6f60d88785861150e490da5445d2c6f3b33d505962721162b87d) |
|||
vite: 7.3.3(@types/[email protected])([email protected])([email protected])([email protected])([email protected]) |
|||
vite-node: 5.3.0(@types/[email protected])([email protected])([email protected])([email protected])([email protected]) |
|||
vite-plugin-checker: 0.13.0([email protected]([email protected]))([email protected])([email protected])([email protected](@types/[email protected])([email protected])([email protected])([email protected])([email protected]))([email protected]([email protected])) |
|||
@ -10850,7 +10853,7 @@ snapshots: |
|||
ultrahtml: 1.6.0 |
|||
uncrypto: 0.1.3 |
|||
unctx: 2.5.0 |
|||
unenv: 2.0.0-rc.24 |
|||
unenv: 2.0.0-rc.24(patch_hash=0caa5c5d7b4e6f60d88785861150e490da5445d2c6f3b33d505962721162b87d) |
|||
unimport: 6.3.0([email protected]) |
|||
unplugin-utils: 0.3.1 |
|||
unstorage: 1.17.5([email protected](@libsql/[email protected])([email protected](@libsql/[email protected])))([email protected]) |
|||
@ -12175,7 +12178,7 @@ snapshots: |
|||
|
|||
[email protected]: {} |
|||
|
|||
[email protected]: |
|||
[email protected](patch_hash=0caa5c5d7b4e6f60d88785861150e490da5445d2c6f3b33d505962721162b87d): |
|||
dependencies: |
|||
pathe: 2.0.3 |
|||
|
|||
|
|||
Loading…
Reference in new issue