Skip to content

Commit d7a00f2

Browse files
authored
Use ref?
1 parent 24712ba commit d7a00f2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

.github/workflows/Label.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
if: github.head_ref != 'action/ship-publicapi' # Same branch name specified in Release.yml
1313
run: |
1414
git fetch origin ${{ github.base_ref }}
15-
$changes = git diff --numstat --shortstat origin/${{ github.base_ref }}...${{ github.head_ref }} -- '**/PublicApi.Shipped.txt'
15+
$changes = git diff --numstat --shortstat origin/${{ github.base_ref }}...${{ github.ref }} -- '**/PublicApi.Shipped.txt'
1616
Write-Output "$changes"
1717
if ($changes) {
1818
Write-Error "Changes detected in PublicApi.Shipped.txt files. Public API changes must be shipped through the release process, not in regular pull requests."
@@ -24,7 +24,7 @@ jobs:
2424
git fetch origin ${{ github.base_ref }}
2525
2626
# Determine the appropriate label (Sync these labels with release-drafter.yml)
27-
if ("${{ github.head_ref }}" -eq "action/ship-publicapi") { # Same branch name specified in Release.yml
27+
if ("${{ github.ref }}" -eq "action/ship-publicapi") { # Same branch name specified in Release.yml
2828
$labels = @('Type/Housekeeping')
2929
Write-Output "This is a ship-publicapi PR, labeling as Type/Maintenance"
3030
} else {

0 commit comments

Comments
 (0)