mirror of
https://github.com/SukkaW/Surge.git
synced 2026-01-29 01:51:52 +08:00
CI: only enable why-is-node-running in GHA debug logging mode
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
import { isCI } from 'ci-info';
|
||||
import { noop } from 'foxts/noop';
|
||||
import { basename, extname } from 'node:path';
|
||||
import process from 'node:process';
|
||||
@@ -134,8 +135,10 @@ export function task(importMetaMain: boolean, importMetaPath: string) {
|
||||
}
|
||||
|
||||
export async function whyIsNodeRunning() {
|
||||
const mod = await import('why-is-node-running');
|
||||
return mod.default();
|
||||
if (isCI && process.env.RUNNER_DEBUG === '1') {
|
||||
const mod = await import('why-is-node-running');
|
||||
return mod.default();
|
||||
}
|
||||
}
|
||||
|
||||
// const isSpan = (obj: any): obj is Span => {
|
||||
|
||||
Reference in New Issue
Block a user