From da0b444515cf49d584b1352b05dd74df5a069913 Mon Sep 17 00:00:00 2001 From: Vittorio Palmisano Date: Wed, 15 May 2024 15:51:27 +0200 Subject: [PATCH] refactor runShellCommand --- src/utils.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/utils.ts b/src/utils.ts index e7b8436..3cf4d89 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -648,9 +648,11 @@ export async function runShellCommand( let stdout = '' let stderr = '' p.stdout.on('data', data => { + if (stdout.length > 10 * 1024) return stdout += data }) p.stderr.on('data', data => { + if (stderr.length > 10 * 1024) return stderr += data }) p.once('error', err => reject(err))