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:
parent
6bed0f27ec
commit
057306fba1
1 changed files with 7 additions and 2 deletions
|
|
@ -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'
|
||||
|
|
|
|||
Loading…
Reference in a new issue