From 8c0cdd40ef837764fd65ac6d926c5739aa558756 Mon Sep 17 00:00:00 2001 From: Nikita Andriyanov Date: Tue, 24 Dec 2024 12:24:30 +0300 Subject: [PATCH] try lfs --- .github/workflows/build.yaml | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 30e5be4..05e5759 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -10,12 +10,19 @@ jobs: IMAGE_TAG: ${{ github.sha }} steps: - name: Checkout + uses: actions/checkout@master + - name: Checkout LFS run: | - git init - git remote add origin ${{ github.server_url }}/${{ github.repository }}.git - git fetch --depth 1 origin ${{ github.ref }} - git checkout FETCH_HEAD - git lfs pull + UrlBase=$GITHUB_SERVER_URL; \ + UrlLfsBase=$UrlBase/${{ github.repository }}.git/info/lfs/objects; \ + Auth=`/usr/bin/git config --get --local http.$UrlBase/.extraheader`; \ + /usr/bin/git config --local http.${UrlLfsBase}/batch.extraheader "$Auth"; \ + /usr/bin/git config --local http.${UrlLfsBase}/.extraheader '' + + git config --local lfs.transfer.maxretries 1 + + /usr/bin/git lfs fetch origin refs/remotes/origin/${{ github.ref_name }} + /usr/bin/git lfs checkout - name: Use ssh key uses: webfactory/ssh-agent@v0.9.0 with: