Skip to content

Commit b15da96

Browse files
authored
issue/517 Fixed missing matches in stdout (#165)
1 parent f9acaa5 commit b15da96

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

lib/integration/AdaptFramework/build.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,12 @@ export default async function adaptBuild ({
2828
].filter(Boolean).join(' ');
2929
exec(cmd, { cwd }, (error, stdout, stderr) => {
3030
if(error || stderr) {
31+
const matches = stdout.match(/>> Error:\s(.+)\s/);
3132
const e = new Error('grunt tasks failed')
3233
e.cmd = cmd;
33-
e.raw = stdout.match(/>> Error:\s(.+)\s/)[1]
34+
e.raw = matches?.[1] ?? stdout;
35+
e.source = error;
36+
e.stderr = stderr;
3437
return reject(e)
3538
}
3639
resolve()

0 commit comments

Comments
 (0)