Skip to content

Commit ccd2978

Browse files
Merge pull request #269 from chocolatey/branchTarget
(build) Allows External Forks to Target Builds
2 parents e6c4929 + 05c36a1 commit ccd2978

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

.github/workflows/test.yml

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,10 @@ on:
2121
description: The configurations to test with.
2222
default: self-signed, single, wildcard
2323

24-
pull_request:
25-
paths:
26-
- files/**.json
27-
- "**.ps1"
28-
- scripts/**.ps1
24+
pull_request_target:
25+
paths-ignore:
26+
- .github/workflows/**
27+
2928
types:
3029
- opened
3130
- reopened
@@ -361,7 +360,7 @@ jobs:
361360
name: Cleanup Test Resources
362361
runs-on: ubuntu-latest
363362
needs: [build, runner_test_deploy]
364-
if: success() || failure()
363+
if: always()
365364
steps:
366365
- name: Login to Azure
367366
uses: azure/login@v2
@@ -383,12 +382,12 @@ jobs:
383382
"X-GitHub-Api-Version" = "2022-11-28"
384383
}
385384
}
386-
Invoke-RestMethod @DeleteArgs
385+
Invoke-RestMethod @DeleteArgs -ErrorAction SilentlyContinue
387386
}
388387
389388
$ResourceGroupName = "qsg-testing"
390389
if ('${{ github.run_id }}' -ne "`$`{{ github.run_id }}") {$ResourceGroupName += '-${{ github.run_id }}'}
391390
if (Get-AzResourceGroup -ResourceGroupName $ResourceGroupName -ErrorAction SilentlyContinue) {
392-
Remove-AzResourceGroup -ResourceGroupName $ResourceGroupName -Force # -AsJob
391+
Remove-AzResourceGroup -ResourceGroupName $ResourceGroupName -Force
393392
}
394393
azPSVersion: latest

0 commit comments

Comments
 (0)