ci(windows-smoke): fetch the branch to build into a worktree
A second actions/checkout in the same job fails on the Windows host runner (Access is denied on the cached action's pack file). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PPmy3tPq869XDW4njjVaKA
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
9f0f782bbb
commit
e2e43aa08c
@@ -43,12 +43,16 @@ jobs:
|
||||
Invoke-WebRequest -Uri "$env:GITEA_URL/$env:REPO/releases/download/latest/LotusChat-x86_64-setup.exe" -OutFile smoke-installer\setup.exe
|
||||
Get-Item smoke-installer\setup.exe | Select-Object Name, Length
|
||||
|
||||
# A second actions/checkout in one job trips over the host runner's
|
||||
# action cache on Windows ("Access is denied" on its pack files), so
|
||||
# fetch the branch into a worktree with plain git instead.
|
||||
- name: Check out the branch to build
|
||||
if: ${{ inputs.ref != '' }}
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
ref: ${{ inputs.ref }}
|
||||
path: build-src
|
||||
shell: powershell
|
||||
run: |
|
||||
git fetch --depth=1 origin "${{ inputs.ref }}"
|
||||
git worktree add --force build-src FETCH_HEAD
|
||||
git -C build-src log --oneline -1
|
||||
|
||||
- name: Build the branch
|
||||
if: ${{ inputs.ref != '' }}
|
||||
|
||||
Reference in New Issue
Block a user