From a4e8e23768e59e16d1141150c1405db6cfc5c1bd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=80=97=E5=AD=90?= Date: Fri, 28 Feb 2025 00:42:45 +0800 Subject: [PATCH] ci: update --- .github/workflows/checksums.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/checksums.yml b/.github/workflows/checksums.yml index 46d8c71..6ed94fc 100644 --- a/.github/workflows/checksums.yml +++ b/.github/workflows/checksums.yml @@ -11,16 +11,22 @@ jobs: - name: Checkout repository uses: actions/checkout@v4 with: + ref: ${{ github.head_ref }} lfs: true - name: Generate checksums run: | set -e + git lfs install --local + # disable credentials by actions/checkout for LFS endpoints + git -c "http.${GITHUB_SERVER_URL}/storage/lfs/.extraHeader=" lfs pull IFS=$'\n' for file in $(git ls-files | grep "^panel/" | grep -v ".sha256$" | grep -v ".txt$"); do filename=$(basename "$file"); sha256sum -b "$file" | sed "s|$file|$filename|" > "${file}.sha256"; done + unset IFS - name: Commit changes uses: actions/git-auto-commit-action@v5 with: - commit_message: "chore: update checksum files" + commit_message: "chore: update checksums" + file_pattern: "*.sha256"