From 582ac4c3461973f6de85f01d2ff9b2da18e310f3 Mon Sep 17 00:00:00 2001 From: Alexander Sehr Date: Fri, 29 Dec 2023 23:44:42 +0100 Subject: [PATCH] fix: Re-enabled post-publish validation (#754) ## Description Recovered post-publish validation environment variables that were incorrectly removed in PR: https://github.com/Azure/bicep-registry-modules/pull/673 --------- Co-authored-by: Erika Gressi <56914614+eriqua@users.noreply.github.com> --- .github/actions/templates/avm-publishModule/action.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/actions/templates/avm-publishModule/action.yml b/.github/actions/templates/avm-publishModule/action.yml index 20cb632d79..7192a29073 100644 --- a/.github/actions/templates/avm-publishModule/action.yml +++ b/.github/actions/templates/avm-publishModule/action.yml @@ -66,7 +66,10 @@ runs: Write-Verbose "Invoke function with" -Verbose Write-Verbose ($functionInput | ConvertTo-Json | Out-String) -Verbose - Publish-ModuleFromPathToPBR @functionInput -Verbose + if($publishOutputs = Publish-ModuleFromPathToPBR @functionInput -Verbose) { + Write-Output ('{0}={1}' -f 'version', $publishOutputs.version) >> $env:GITHUB_OUTPUT + Write-Output ('{0}={1}' -f 'publishedModuleName', $publishOutputs.publishedModuleName) >> $env:GITHUB_OUTPUT + } Write-Output '::endgroup::'