From e6831f705843bb62d19e4155792b1d978d58b3c8 Mon Sep 17 00:00:00 2001 From: Leonid Pospelov Date: Mon, 23 Dec 2024 04:49:27 +0500 Subject: [PATCH] internal: add caching to GitHub Actions (#2278) --- .github/actions/pr_base/action.yml | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/.github/actions/pr_base/action.yml b/.github/actions/pr_base/action.yml index 8d811e8d13..8ff36593c2 100644 --- a/.github/actions/pr_base/action.yml +++ b/.github/actions/pr_base/action.yml @@ -66,6 +66,19 @@ runs: git commit -m "Merge PRs ${{inputs.DEPLOY_BRANCH}}" shell: powershell + - name: Get Current Git SHA + id: repo_sha + shell: powershell + run: | + $sha = git rev-parse HEAD + echo "sha=$sha" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append + + - name: Cache build dir + uses: actions/cache@v4 + with: + path: ${{github.workspace}}/build + key: ${{ runner.os }}-skymp-${{ hashFiles('./build-metadata.json') }}-${{ env.sha }} + - name: Early build skymp5-client run: | cd ${{github.workspace}}/skymp5-client