Replace set-output with append to GITHUB_OUTPUT

This commit is contained in:
Phil Jay
2022-10-19 09:23:10 +11:00
parent e7c0a5aac2
commit ced1d4ac1d
2 changed files with 11 additions and 11 deletions

View File

@@ -76,7 +76,7 @@ fi
if [[ "${current_ref}" != "refs/heads/${default_branch}" ]] ; then
pre_release="pre.${git_commit}"
new_version="${new_version}-${pre_release}"
echo "::set-output name=pre-release-label::${pre_release}"
echo "PRE_RELEASE_LABEL=${pre_release}" >> "${GITHUB_OUTPUT}"
fi
if [[ -z "$(echo "${new_version}" | ${grep} -P "${pcre_semver}")" ]] ; then
@@ -88,11 +88,11 @@ fi
echo " The new version is ${new_version}"
echo "::set-output name=version::${new_version}"
echo "::set-output name=v-version::v${new_version}"
echo "::set-output name=major-version::${version_array[0]}"
echo "::set-output name=minor-version::${version_array[1]}"
echo "::set-output name=patch-version::${version_array[2]}"
echo "::set-output name=major-v-version::v${version_array[0]}"
echo "::set-output name=minor-v-version::v${version_array[1]}"
echo "::set-output name=patch-v-version::v${version_array[2]}"
echo "VERSION=${new_version}" >> "${GITHUB_OUTPUT}"
echo "V_VERSION=v${new_version}" >> "${GITHUB_OUTPUT}"
echo "MAJOR_VERSION=${version_array[0]}" >> "${GITHUB_OUTPUT}"
echo "MINOR_VERSION=${version_array[1]}" >> "${GITHUB_OUTPUT}"
echo "PATCH_VERSION=${version_array[2]}" >> "${GITHUB_OUTPUT}"
echo "MAJOR_V_VERSION=v${version_array[0]}" >> "${GITHUB_OUTPUT}"
echo "MINOR_V_VERSION=v${version_array[1]}" >> "${GITHUB_OUTPUT}"
echo "PATCH_V_VERSION=v${version_array[2]}" >> "${GITHUB_OUTPUT}"

View File

@@ -61,5 +61,5 @@ fi
echo " The current normal version is ${current_version}"
echo "::set-output name=current-version::${current_version}"
echo "::set-output name=current-v-version::v${current_version}"
echo "CURRENT_VERSION=${current_version}" >> "${GITHUB_OUTPUT}"
echo "CURRENT_V_VERSION=v${current_version}" >> "${GITHUB_OUTPUT}"