From cf6befa2e87759321f0707019b9c2326689307e4 Mon Sep 17 00:00:00 2001 From: Matt Travi Date: Sun, 20 Nov 2022 23:22:32 -0600 Subject: [PATCH] fix(secrets-masking): used the proper named import from hook-std to enable masking for stderr (#2619) --- bin/semantic-release.js | 1 - index.js | 4 ++-- lib/plugins/pipeline.js | 2 +- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/bin/semantic-release.js b/bin/semantic-release.js index e9da11ca4c..3cffd5d57a 100755 --- a/bin/semantic-release.js +++ b/bin/semantic-release.js @@ -37,7 +37,6 @@ execa('git', ['--version']) process.exit(1); }); -// Node 10+ from this point on cli() .then((exitCode) => { process.exitCode = exitCode; diff --git a/index.js b/index.js index 0f3af2cb69..ee19e073a1 100644 --- a/index.js +++ b/index.js @@ -2,7 +2,7 @@ import {createRequire} from 'node:module'; import {pick} from 'lodash-es'; import * as marked from 'marked'; import envCi from 'env-ci'; -import {hookStdout} from 'hook-std'; +import {hookStd} from 'hook-std'; import semver from 'semver'; import AggregateError from 'aggregate-error'; import hideSensitive from './lib/hide-sensitive.js'; @@ -251,7 +251,7 @@ async function callFail(context, plugins, err) { } export default async (cliOptions = {}, {cwd = process.cwd(), env = process.env, stdout, stderr} = {}) => { - const {unhook} = hookStdout( + const {unhook} = hookStd( {silent: false, streams: [process.stdout, process.stderr, stdout, stderr].filter(Boolean)}, hideSensitive(env) ); diff --git a/lib/plugins/pipeline.js b/lib/plugins/pipeline.js index 3ff6f30d88..c96415d312 100644 --- a/lib/plugins/pipeline.js +++ b/lib/plugins/pipeline.js @@ -23,7 +23,7 @@ import {extractErrors} from '../utils.js'; * @param {Function} [options.getNextInput=identity] Function called after each step is executed, with the last step input and the current current step result; the returned value will be used as the input of the next step. * @param {Function} [options.transform=identity] Function called after each step is executed, with the current step result, the step function and the last step input; the returned value will be saved in the pipeline results. * - * @return {Pipeline} A Function that execute the `steps` sequencially + * @return {Pipeline} A Function that execute the `steps` sequentially */ export default (steps, {settleAll = false, getNextInput = identity, transform = identity} = {}) => async (input) => { const results = [];