diff --git a/.gitea/workflows/build_blog_image.yml b/.gitea/workflows/build_blog_image.yml index 16f1419..d73b20b 100644 --- a/.gitea/workflows/build_blog_image.yml +++ b/.gitea/workflows/build_blog_image.yml @@ -11,6 +11,15 @@ jobs: steps: - name: checkout code uses: actions/checkout@v3 + # with: + # lfs: 'true' + - name: Checkout LFS + run: | + function EscapeForwardSlash() { echo "$1" | sed 's/\//\\\//g'; } + readonly ReplaceStr="EscapeForwardSlash ${{ gitea.repository }}.git/info/lfs/objects/batch"; sed -i "s/\(\[http\)\( \".*\)\"\]/\1\2`$ReplaceStr`\"]/" .git/config + git config --local lfs.transfer.maxretries 1 + /usr/bin/git lfs fetch origin refs/remotes/origin/${{ gitea.ref_name }} + /usr/bin/git lfs checkout - name: Set up QEMU uses: docker/setup-qemu-action@v2 - name: Set up Docker Buildx diff --git a/README.md b/README.md index 192e85d..beb29de 100644 --- a/README.md +++ b/README.md @@ -5,4 +5,5 @@ export PATH=$PATH:/usr/local/go/bin CGO_ENABLED=1 go install -tags extended github.com/gohugoio/hugo@latest git submodule update --recursive +git lfs pull ``` \ No newline at end of file