-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
@actions/cache fails on Windows when GNU tar from MSYS2 is in PATH #632
Comments
See related discussion in November 24, 2020 3:28 PM:
|
I think replacing |
…YS2 tar * See actions/toolkit#632 * Fixes ruby#102
…YS2 tar * See actions/toolkit#632 * Fixes ruby#102
Thank you for fixing this, @aiqiaoy, I can confirm it works now :) |
actions/cache@v2 doesn't work on windows-2016 images, since those contain the GNU tar, which cannot work with \ as path separator. This was fixed in package @actions/cache v1.0.5, which is used by action actions/[email protected] [1][2]. In addition, it simply couldn't find tar.exe on those images thanks to my action cleanup-path, which removed the corresponding directory (I think it was Git's bin/) from PATH. It worked for windows-2019 images thanks to them containing tar.exe in System32. Solved by turning cleanup-path into a JavaScript action with a "post" step, which restores the original PATH value. [1]: actions/runner-images#480 [2]: actions/toolkit#632
If someone stumbles upon this like me: simply pin the version to the latest |
Cache maven repository to decrease build times (see #1677 ) * Using latest cache action release explicitly (see egor-tensin/cmake-common@eca875b and actions/toolkit#632) Co-authored-by: Jonas Hecht <[email protected]>
Cache maven repository to decrease build times (see #1677 ) * Using latest cache action release explicitly (see egor-tensin/cmake-common@eca875b and actions/toolkit#632) Co-authored-by: Jonas Hecht <[email protected]>
Cache maven repository to decrease build times (see #1677 ) * Using latest cache action release explicitly (see egor-tensin/cmake-common@eca875b and actions/toolkit#632) Co-authored-by: Jonas Hecht <[email protected]>
Cache maven repository to decrease build times (see #1677 ) * Using latest cache action release explicitly (see egor-tensin/cmake-common@eca875b and actions/toolkit#632) Co-authored-by: Jonas Hecht <[email protected]>
Describe the bug
When
C:\msys64\usr\bin
is in the path on Windows, and using@actions/cache
, I noticed that cache saving always fails:ruby/setup-ruby#102
https://github.com/ruby/setup-ruby/runs/1370892940?check_suite_focus=true
The problem seems to be that the cache paths written to manifest.txt use
\\
and not/
, which I would think GNU tar expects.On https://github.com/eregon/setup-ruby/runs/1392737782?check_suite_focus=true#step:3:100 we can see the cache paths written to manifest.txt is
["vendor\\bundle"]
but it should most likely uses/
as separator for GNU tar.To Reproduce
Minimal repro using actions/cache:
https://github.com/eregon/setup-ruby-test/runs/1392827825?check_suite_focus=true#step:10:3
Full repro using the @actions/cache package:
Expand the
bundle install
group ofruby/setup-ruby@v1
.Expected behavior
It should save the cache successfully.
The text was updated successfully, but these errors were encountered: