mirror of
https://gitea.wildfiregames.com/0ad/0ad.git
synced 2026-06-20 23:24:16 +00:00
Check LFS pointers integrity in an action
Running the checks here instead of in repository hooks will prevent Gitea from hanging during pushes.
This commit is contained in:
@@ -3,7 +3,22 @@ name: checkrefs
|
||||
on:
|
||||
- push
|
||||
- pull_request
|
||||
env:
|
||||
BASE_SHA: ${{ github.event.pull_request.base.sha }}
|
||||
HEAD_SHA: ${{ github.event.pull_request.head.sha }}
|
||||
|
||||
jobs:
|
||||
lfscheck:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Fetch the base branch
|
||||
run: git fetch origin ${{ env.BASE_SHA }}
|
||||
|
||||
- name: Check that LFS files are correctly stored as pointers
|
||||
run: git-lfs fsck --pointers ${{ env.BASE_SHA }}..${{ env.HEAD_SHA }}
|
||||
|
||||
checkrefs:
|
||||
runs-on: ubuntu-latest
|
||||
env:
|
||||
|
||||
Reference in New Issue
Block a user