We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2400288 commit 6471002Copy full SHA for 6471002
1 file changed
‎.github/workflows/validate-properties-links.yml‎
@@ -19,6 +19,7 @@ jobs:
19
uses: actions/checkout@v6
20
with:
21
ref: ${{ github.event.pull_request.head.sha }}
22
+ fetch-depth: 0
23
24
- name: Set up Python
25
uses: actions/setup-python@v6
@@ -33,7 +34,11 @@ jobs:
33
34
id: changed_files
35
run: |
36
# Get list of changed .properties files
- git fetch origin ${{ github.event.pull_request.base.ref }}
37
+ # Make sure we have the base branch
38
+ git fetch origin ${{ github.event.pull_request.base.ref }} --depth=1 || git fetch origin ${{ github.event.pull_request.base.ref }}
39
+
40
+ # Use ... to find changes between the common ancestor and HEAD
41
+ # This is more robust for PRs
42
CHANGED_FILES=$(git diff --name-only origin/${{ github.event.pull_request.base.ref }}...HEAD | grep '\.properties$' || true)
43
44
if [ -z "$CHANGED_FILES" ]; then
0 commit comments