Skip to content

Replace deprecated set-output command with environment file#172691

Merged
joaomoreno merged 1 commit intomicrosoft:mainfrom
jongwooo:chore/replace-deprecated-command-with-environment-file
Jan 31, 2023
Merged

Replace deprecated set-output command with environment file#172691
joaomoreno merged 1 commit intomicrosoft:mainfrom
jongwooo:chore/replace-deprecated-command-with-environment-file

Conversation

@jongwooo
Copy link
Contributor

@jongwooo jongwooo commented Jan 28, 2023

Signed-off-by: jongwooo [email protected]

Description

Resolve #172689

Update workflows to use environment file instead of deprecated set-output command.
For more information, see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/

I found the workflow files that use set-output command through the following command:

$ find .github/workflows -name '*.yml' | xargs egrep '\bset-output\b'

AS-IS

run: echo "::set-output name=value::$(node build/azure-pipelines/common/computeNodeModulesCacheKey.js)"
run: echo "::set-output name=dir::$(yarn cache dir)"

TO-BE

run: echo "value=$(node build/azure-pipelines/common/computeNodeModulesCacheKey.js)" >> $GITHUB_OUTPUT
run: echo "dir=$(yarn cache dir)" >> $GITHUB_OUTPUT

@jongwooo
Copy link
Contributor Author

@microsoft-github-policy-service agree

@roblourens roblourens assigned joaomoreno and alexdima and unassigned roblourens Jan 30, 2023
@joaomoreno joaomoreno added this to the February 2023 milestone Jan 31, 2023
@joaomoreno
Copy link
Member

Thanks!

@joaomoreno joaomoreno enabled auto-merge (squash) January 31, 2023 11:10
@joaomoreno joaomoreno merged commit e4b9950 into microsoft:main Jan 31, 2023
@jongwooo jongwooo deleted the chore/replace-deprecated-command-with-environment-file branch January 31, 2023 11:47
@github-actions github-actions bot locked and limited conversation to collaborators Mar 17, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Replace deprecated set-output command with environment file

5 participants