prquicktest 2.0.0 → 2.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/prquicktest.mjs +7 -2
- package/package.json +1 -1
package/bin/prquicktest.mjs
CHANGED
|
@@ -243,8 +243,13 @@ function runInShell(shell, code) {
|
|
|
243
243
|
const line = stdoutBuf.slice(0, newlineIdx);
|
|
244
244
|
stdoutBuf = stdoutBuf.slice(newlineIdx + 1);
|
|
245
245
|
|
|
246
|
-
|
|
247
|
-
|
|
246
|
+
const markerIdx = line.indexOf(markerPrefix);
|
|
247
|
+
if (markerIdx !== -1) {
|
|
248
|
+
// Output any content before the marker (e.g., if previous command didn't end with newline)
|
|
249
|
+
if (markerIdx > 0) {
|
|
250
|
+
process.stdout.write(line.slice(0, markerIdx) + '\n');
|
|
251
|
+
}
|
|
252
|
+
const exitCode = parseInt(line.slice(markerIdx + markerPrefix.length), 10);
|
|
248
253
|
cleanup();
|
|
249
254
|
resolve({ success: exitCode === 0, code: exitCode });
|
|
250
255
|
return;
|