Skip to content

Commit cdbfa9b

Browse files
committed
Replace usage of deprecated ::set-output in GitHub workflows
Fixes #6
1 parent f2198aa commit cdbfa9b

File tree

2 files changed

+9
-7
lines changed

2 files changed

+9
-7
lines changed

.github/workflows/codeql.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,11 @@ jobs:
2323
# Switch to submodule and get Git tag
2424
cd codeql
2525
# Fetch tags (and only tags), see https://stackoverflow.com/a/20608181
26-
git fetch origin 'refs/tags/*:refs/tags/*' --quiet
26+
git fetch origin 'refs/tags/*:refs/tags/*' --quiet
2727
tag=$(git describe --exact-match --exclude "codeql-cli/latest")
28+
# Remove 'codeql-cli/' prefix
2829
version="${tag#codeql-cli/}"
29-
echo "::set-output name=version::${version}"
30+
echo "version=${version}" >> $GITHUB_OUTPUT
3031
echo "Submodule version: ${version}"
3132
3233
# Based on https://github.com/github/codeql/blob/45c942866830bec3463598774012a33a2cfaff96/.github/workflows/query-list.yml
@@ -46,7 +47,7 @@ jobs:
4647
id: codeql-version
4748
run: |
4849
./codeql-cli/codeql/codeql version --format=terse
49-
echo "::set-output name=version::$(./codeql-cli/codeql/codeql version --format=terse)"
50+
echo "version=$(./codeql-cli/codeql/codeql version --format=terse)" >> $GITHUB_OUTPUT
5051
5152
# TODO: Once available, change this to update the cache, see https://github.com/actions/cache/issues/342
5253
# For now include the CodeQL CLI version in the cache key to invalidate the cache, see https://github.com/github/vscode-codeql/issues/730#issuecomment-764855019

.github/workflows/update-codeql.yml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,17 +23,18 @@ jobs:
2323
# Switch to submodule and get Git tag
2424
cd codeql
2525
# Fetch tags (and only tags), see https://stackoverflow.com/a/20608181
26-
git fetch origin 'refs/tags/*:refs/tags/*' --quiet
26+
git fetch origin 'refs/tags/*:refs/tags/*' --quiet
2727
tag=$(git describe --exact-match --exclude "codeql-cli/latest")
28+
# Remove 'codeql-cli/' prefix
2829
version="${tag#codeql-cli/}"
29-
echo "::set-output name=version::${version}"
30+
echo "version=${version}" >> $GITHUB_OUTPUT
3031
echo "Submodule version: ${version}"
3132
3233
latest_version_tag=$(git tag --sort=-version:refname | grep "codeql-cli/" | head --lines=1)
33-
echo "::set-output name=latest-version-tag::${latest_version_tag}"
34+
echo "latest-version-tag=${latest_version_tag}" >> $GITHUB_OUTPUT
3435
3536
latest_version="${latest_version_tag#codeql-cli/}"
36-
echo "::set-output name=latest-version::${latest_version}"
37+
echo "latest-version=${latest_version}" >> $GITHUB_OUTPUT
3738
echo "Latest version: ${latest_version}"
3839
3940
- name: Prepare CodeQL version update

0 commit comments

Comments
 (0)