@@ -37,13 +37,13 @@ jobs:
3737 branch : ${{ fromJson(needs.determine-branches.outputs.branches) }}
3838
3939 steps :
40+ # Shallow checkout of the branch tip only. The generated Markdown is never
41+ # pushed to the branch itself (see below), only tagged, so the diff target is
42+ # the latest tag — fetched individually in "Find the last tag" instead of
43+ # pulling the full history + every daily tag snapshot (which took minutes).
4044 - uses : actions/checkout@v4
4145 with :
4246 ref : ${{ matrix.branch }}
43- # Full history + tags: the generated Markdown is never pushed to the branch
44- # itself (see below), only tagged, so tags are the only place to diff against.
45- fetch-depth : 0
46- fetch-tags : true
4747
4848 - name : Set up Python
4949 uses : actions/setup-python@v3
@@ -61,13 +61,13 @@ jobs:
6161 php-version : " 8.3"
6262 coverage : none
6363
64- - name : Generate token
65- id : generate_token
66- uses : actions/create-github-app-token@v2
67- with :
68- app-id : ${{ secrets.AUTOMATION_CLIENT_ID }}
69- private-key : ${{ secrets.AUTOMATION_CLIENT_SECRET }}
70- owner : ${{ github.repository_owner }}
64+ # - name: Generate token
65+ # id: generate_token
66+ # uses: actions/create-github-app-token@v2
67+ # with:
68+ # app-id: ${{ secrets.AUTOMATION_CLIENT_ID }}
69+ # private-key: ${{ secrets.AUTOMATION_CLIENT_SECRET }}
70+ # owner: ${{ github.repository_owner }}
7171
7272 - name : Add composer keys for private packagist
7373 run : |
7676 env :
7777 SATIS_NETWORK_KEY : ${{ secrets.SATIS_NETWORK_KEY }}
7878 SATIS_NETWORK_TOKEN : ${{ secrets.SATIS_NETWORK_TOKEN }}
79- GITHUB_TOKEN : ${{ steps.generate_token.outputs.token }}
79+ GITHUB_TOKEN : ${{ secrets.MY_GITHUB_TOKEN }} # ${{ steps.generate_token.outputs.token }}
8080
8181 # Needed to resolve the PHP API classes referenced by the docs to
8282 # their vendor/ source paths (dump_class_paths.php).
@@ -101,7 +101,14 @@ jobs:
101101 env :
102102 BRANCH : ${{ matrix.branch }}
103103 run : |
104- latest_tag=$(git tag --list "${BRANCH}.*" | sort -t. -k1,1n -k2,2n -k3,3n -k4,4n | tail -1)
104+ # List tag names on the remote (no object download), then fetch only the
105+ # latest one — the single commit the change check diffs against.
106+ latest_tag=$(git ls-remote --tags origin "refs/tags/${BRANCH}.*" \
107+ | awk '{print $2}' | sed 's|^refs/tags/||' | grep -v '\^{}$' \
108+ | sort -t. -k1,1n -k2,2n -k3,3n -k4,4n | tail -1)
109+ if [[ -n "$latest_tag" ]]; then
110+ git fetch --depth=1 origin "refs/tags/${latest_tag}:refs/tags/${latest_tag}"
111+ fi
105112 echo "latest_tag=${latest_tag}" >> "$GITHUB_OUTPUT"
106113
107114 - name : Check for content changes since the last tag
0 commit comments