Skip to content

Commit edd7713

Browse files
committed
Only echo command if we are streaming the stdout
1 parent 90c42c4 commit edd7713

6 files changed

+12
-8
lines changed

lib/actions-util.js

+3-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/actions-util.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/setup-codeql.js

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/setup-codeql.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/actions-util.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -527,7 +527,9 @@ export async function runTool(
527527
): Promise<string> {
528528
let stdout = "";
529529
let stderr = "";
530-
process.stdout.write(`[command]${cmd} ${args.join(" ")}\n`);
530+
if (!opts.noStreamStdout) {
531+
process.stdout.write(`[command]${cmd} ${args.join(" ")}\n`);
532+
}
531533
const exitCode = await new toolrunner.ToolRunner(cmd, args, {
532534
ignoreReturnCode: true,
533535
listeners: {

src/setup-codeql.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -557,9 +557,9 @@ export const downloadCodeQL = async function (
557557
);
558558

559559
logger.info(
560-
`Added CodeQL bundle to the tool cache (${
561-
performance.now() - toolcacheStart
562-
} ms).`,
560+
`Added CodeQL bundle to the tool cache (${Math.round(
561+
performance.now() - toolcacheStart,
562+
)} ms).`,
563563
);
564564

565565
// Defensive check: we expect `cacheDir` to copy the bundle to a new location.

0 commit comments

Comments
 (0)