@@ -10,6 +10,7 @@ pester_test:
1010 tags :
1111 - windows
1212 script :
13+ - echo "Running tests -> pester_test"
1314 - pwsh
1415 - install-module -name 'pester' -RequiredVersion '5.5.0' -Repository 'psgallery' -confirm:$false
1516 - Import-Module -name pester -RequiredVersion '5.5.0'
@@ -21,6 +22,7 @@ pester_test_coverage:
2122 tags :
2223 - windows
2324 script :
25+ - echo "Running tests -> pester_test_coverage"
2426 - pwsh
2527 - install-module -name 'pester' -RequiredVersion '5.5.0' -Repository 'psgallery' -confirm:$false
2628 - Import-Module -name pester -RequiredVersion '5.5.0'
@@ -35,6 +37,7 @@ script_analyzer:
3537 tags :
3638 - windows
3739 script :
40+ - echo "Running tests -> script_analyzer"
3841 - pwsh
3942 - find-module -name PSScriptAnalyzer -Repository PSGallery | install-module -Scope CurrentUser -Force -SkipPublisherCheck
4043 - Import-Module -Name PSScriptAnalyzer
@@ -49,7 +52,7 @@ build_module:
4952 tags :
5053 - windows
5154 rules :
52- - if : ' $CI_BUILD_STAGE == "tests" && $CI_BUILD_STATUS == "success"'
55+ - if : ' $CI_COMMIT_BRANCH == "main" && $ CI_BUILD_STAGE == "tests" && $CI_BUILD_STATUS == "success"'
5356 script :
5457 - pwsh
5558 - Find-Module -name 'psmpacker' -repository 'powershell' | install-Module -force
@@ -66,7 +69,7 @@ create_nuget:
6669 tags :
6770 - windows
6871 rules :
69- - if : ' $CI_BUILD_STAGE == "tests" && $CI_BUILD_STATUS == "success"'
72+ - if : ' $CI_COMMIT_BRANCH == "main" && $ CI_BUILD_STAGE == "tests" && $CI_BUILD_STATUS == "success"'
7073 script :
7174 - pwsh.exe
7275 - find-Module -Repository 'powershell' -Name 'nupsforge' | Install-module -force
@@ -86,7 +89,7 @@ deploy_gitlab:
8689 - pwsh.exe
8790 - .\build\bt3-ci-deploy-pushtogitlab.ps1
8891 rules :
89- - if : ' $CI_BUILD_STAGE == "build" && $CI_BUILD_STATUS == "success"'
92+ - if : ' $CI_COMMIT_BRANCH == "main" && $ CI_BUILD_STAGE == "build" && $CI_BUILD_STATUS == "success"'
9093 artifacts :
9194 paths :
9295 - ./dist/*
@@ -101,7 +104,7 @@ deploy_proget:
101104 - pwsh.exe
102105 - .\build\bt4-ci-deploy-pushtoproget.ps1
103106 rules :
104- - if : ' $CI_BUILD_STAGE == "build" && $CI_BUILD_STATUS == "success"'
107+ - if : ' $CI_COMMIT_BRANCH == "main" && $ CI_BUILD_STAGE == "build" && $CI_BUILD_STATUS == "success"'
105108 artifacts :
106109 paths :
107110 - ./dist/*
0 commit comments