File tree Expand file tree Collapse file tree 1 file changed +14
-11
lines changed Expand file tree Collapse file tree 1 file changed +14
-11
lines changed Original file line number Diff line number Diff line change @@ -853,18 +853,21 @@ stages:
853
853
854
854
jobs :
855
855
- job : DebugInfo
856
- variables :
857
- - name : CreateEnvOnly
858
- value : ${{ parameters.CreateEnvOnly }}
859
- - name : PrintSQLInfoStat
860
- value : " ${{ dependencies.Create_Environments.PrintSQLInfo.result }}"
861
- - name : PrintSQLInfoSuc
862
- value : succeeded('Create_Environments.PrintSQLInfo')
856
+ dependsOn :
857
+ - Create_Environments
863
858
steps :
864
- - script : |
865
- echo "CreateEnvOnly: $(CreateEnvOnly)"
866
- echo "PrintSQLInfoSuc: $(PrintSQLInfoSuc)"
867
- echo "PrintSQLInfoStat: $(PrintSQLInfoStat)"
859
+ - pwsh : |
860
+ # Access the parameter directly
861
+ Write-Host "CreateEnvOnly: ${{ parameters.CreateEnvOnly }}"
862
+
863
+ # Access the outcome of a job from another stage, assuming `Create_Environments` is a stage and `PrintSQLInfo` is a job within that stage.
864
+ $printSQLInfoStatus = '$(stageDependencies.Create_Environments.PrintSQLInfo.result)'
865
+ Write-Host "PrintSQLInfo Status: $printSQLInfoStatus"
866
+
867
+ # Determine if the specific job succeeded
868
+ $printSQLInfoSucceeded = '$[eq(variables[''stageDependencies.Create_Environments.PrintSQLInfo.result''], ''Succeeded'')]'
869
+ Write-Host "PrintSQLInfo Succeeded: $printSQLInfoSucceeded"
870
+
868
871
869
872
- job : Delete_VM
870
873
You can’t perform that action at this time.
0 commit comments