You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am currently evaluating runs-on for my company (totally digging it!) and was ran into some issues with the Windows base and thought this quick fix could be integrated into the base build for others.
After some searching around I found this issue actions/checkout#1985 and a comment mentioned a registry fix resolved the issue. I was able to located this article and patched my runner with the following code but would be handy if the build included this in the future. Thank you!
Run actions/checkout@v4
Syncing repository: [REDACTED]
Getting Git version info
Deleting the contents of 'C:\actions-runner\_work\[REDACTED]\[REDACTED]'
The repository will be downloaded using the GitHub REST API
To create a local Git repository instead, add Git 2.18 or higher to the PATH
Downloading the archive
Writing archive to disk
Extracting the archive
C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -NoLogo -Sta -NoProfile -NonInteractive -ExecutionPolicy Unrestricted -Command "$ErrorActionPreference = 'Stop' ; try { Add-Type -AssemblyName System.IO.Compression.FileSystem } catch { } ; if ((Get-Command -Name Expand-Archive -Module Microsoft.PowerShell.Archive -ErrorAction Ignore)) { Expand-Archive -LiteralPath 'C:\actions-runner\_work\[REDACTED]\[REDACTED]\f3e1a7ee-7cef-40ff-87ab-[35](https://github.com/[REDACTED]/[REDACTED]/actions/runs/13022550513/job/36326025590#step:3:37)420a704e3e.zip' -DestinationPath 'C:\actions-runner\_work\[REDACTED]\[REDACTED]\f3e1a7ee-7cef-40ff-87ab-35420a704e3e' -Force } else {[System.IO.Compression.ZipFile]::ExtractToDirectory('C:\actions-runner\_work\[REDACTED]\[REDACTED]\f3e1a7ee-7cef-40ff-87ab-35420a704e3e.zip', 'C:\actions-runner\_work\[REDACTED]\[REDACTED]\f3e1a7ee-7cef-40ff-87ab-35420a704e3e', $true) }"
Remove-Item : Cannot find path 'C:\actions-runner\_work\[REDACTED]\[REDACTED]\f3e1a7ee-7cef-40ff-87ab-35420a704e3e\[REDACTED]-[REDACTED]-eb82d685fe62c88c5ff4[37](https://github.com/[REDACTED]/[REDACTED]/actions/runs/13022550513/job/36326025590#step:3:39)2e2a600ba02a4b3bda\.editorconfig' because it does not exist.
At
C:\Windows\system32\WindowsPowerShell\v1.0\Modules\Microsoft.PowerShell.Archive\Microsoft.PowerShell.Archive.psm1:411
char:46
+ ... $expandedItems | % { Remove-Item $_ -Force -Recurse }
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : ObjectNotFound: (C:\actions-runn...a\.editorconfig:String) [Remove-Item], ItemNotFoundEx
ception
+ FullyQualifiedErrorId : PathNotFound,Microsoft.PowerShell.Commands.RemoveItemCommand
Error: The process 'C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe' failed with exit code 1
Patch:
# Patch Windows to enable long paths in Windows 10 on RunsOn windows22-base-x64# https://github.com/actions/checkout/issues/1985#issuecomment-2489125043# https://learn.microsoft.com/en-us/windows/win32/fileio/maximum-file-path-limitation?tabs=powershell
- name: Patch - Enable long paths in Windows 10 shell: powershellrun: | New-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\Control\FileSystem" -Name "LongPathsEnabled" -Value 1 -PropertyType DWORD -Force;
The text was updated successfully, but these errors were encountered:
@vx-daniel Thanks for the report, I'll make sure to add it! Windows images are a beast to properly rebuild with all the software as published by GitHub, but I'll get there!
I am currently evaluating runs-on for my company (totally digging it!) and was ran into some issues with the Windows base and thought this quick fix could be integrated into the base build for others.
After some searching around I found this issue actions/checkout#1985 and a comment mentioned a registry fix resolved the issue. I was able to located this article and patched my runner with the following code but would be handy if the build included this in the future. Thank you!
Runner Config:
build-windows log:
Patch:
The text was updated successfully, but these errors were encountered: