ci: use shallow fetch

No need to fetch the entire history. The merge base is likely within the
last couple commits because we require it to be so anyway, because the
repo requires fast-forward merges currently.

skip-changelog, because this doesn't touch library code.
This commit is contained in:
Jonas Schäfer 2025-01-26 17:34:14 +01:00
commit 057306fba1

View file

@ -82,8 +82,13 @@ changelog-update:
- apk add --no-cache python3 git
- python3 --version
- git version
- git fetch origin main
- git log --oneline "${CI_MERGE_REQUEST_DIFF_BASE_SHA}.." --
- git fetch --depth 16 origin main
- |
if ! git log --oneline "${CI_MERGE_REQUEST_DIFF_BASE_SHA}.." --; then
echo "Failed to find revision ${CI_MERGE_REQUEST_DIFF_BASE_SHA}.." >&2
echo "This likely means that you need to rebase your branch." >&2
exit 1
fi
- python3 .forgejo/workflows/check-changelog.py
rules:
- if: $CI_PIPELINE_SOURCE == 'merge_request_event'