authorgravatar for git@paperclover.netclover caruso <git@paperclover.net> 2025-10-13 23:13:29-07:00
committergravatar for git@paperclover.netclover caruso <git@paperclover.net> 2025-10-18 10:17:56-07:00
log123f64dc0198ef576cae7e75bc02f2742c527d93
tree108e7d675092ad83f7a46b9d8579e29a62a0ceaa
parent7d22daf0aa163766378720a93902c040dff9acb8
signature Commit is signed but in an unrecognized format.

fix: random things trying to run with deno and bun (they dont work)


2 files changed, 14 insertions(+), 8 deletions(-)

lib/log/stack.ts+10-2
...@@ -251,9 +251,10 @@ function getPackageRoot(absPath: string) {...@@ -251,9 +251,10 @@ function getPackageRoot(absPath: string) {
251 const process = globalThis.process;251 const process = globalThis.process;
252 if (!fs || !path || !process) return null;252 if (!fs || !path || !process) return null;
253253
254 const isNodeBuiltin = absPath.startsWith("node:");
254 if (255 if (
255 "Bun" in globalThis &&256 "Bun" in globalThis &&
256 (absPath.startsWith("node:") || absPath.startsWith("internal:"))257 (isNodeBuiltin || absPath.startsWith("internal:"))
257 ) {258 ) {
258 return [259 return [
259 `https://github.com/oven-sh/bun/blob/bun-v${process.versions.bun}/src/js/`,260 `https://github.com/oven-sh/bun/blob/bun-v${process.versions.bun}/src/js/`,
...@@ -261,7 +262,14 @@ function getPackageRoot(absPath: string) {...@@ -261,7 +262,14 @@ function getPackageRoot(absPath: string) {
261 absPath.replace(":", "/") + ".ts",262 absPath.replace(":", "/") + ".ts",
262 ];263 ];
263 }264 }
264 if (absPath.startsWith("node:")) {265 if (isNodeBuiltin) {
266 if ("Deno" in globalThis) {
267 return [
268 `https://github.com/denoland/deno/blob/v${process.versions.deno}/ext/node/polyfills/`,
269 "",
270 absPath.slice(5) + ".js",
271 ];
272 }
265 return [273 return [
266 `https://github.com/nodejs/node/blob/${process.version}/lib/`,274 `https://github.com/nodejs/node/blob/${process.version}/lib/`,
267 "",275 "",
run.js+4-6
...@@ -54,12 +54,10 @@ process.on("uncaughtException", (error) => {...@@ -54,12 +54,10 @@ process.on("uncaughtException", (error) => {
54});54});
5555
56if (fs.existsSync(".env")) {56if (fs.existsSync(".env")) {
57 const env = fs.readFileSync(".env", "utf-8").split("\n").map((x) =>57 const env = fs.readFileSync(".env", "utf-8")
58 x.trim().split("=")58 .split("\n").filter(Boolean)
59 );59 .map((x) => x.trim().split("="));
60 for (const [k, v] of env) {60 for (const [k, v] of env) process.env[k] = v;
61 process.env[k] = v;
62 }
63}61}
6462
65// Load with hooks63// Load with hooks