Skip to content
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

Replace yarn cache rather than nest it #985

Merged
merged 2 commits into from
Feb 16, 2022
Merged

Conversation

joshwlewis
Copy link
Member

@joshwlewis joshwlewis commented Feb 16, 2022

It looks like the current yarn cache save logic (introduced in #978) creates nested caches like this:

- node
  - cache
    - yarn
      - yarn
        - yarn
          - yarn

This PR changes the cache save logic to replace the existing yarn folder in the cache, rather than creating a directory inside.

GUS-W-10519616

@joshwlewis joshwlewis requested a review from a team as a code owner February 16, 2022 00:35
Copy link
Member

@edmorley edmorley left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will prevent new cases from occurring, but will existing nested caches need additional clean-up (either here or in a follow-up PR)?

@joshwlewis
Copy link
Member Author

This will prevent new cases from occurring, but will existing nested caches need additional clean-up (either here or in a follow-up PR)?

This should clean up old caches (by virtue of yarn being pretty good at cleaning up it's own cache).

@joshwlewis joshwlewis merged commit 6c2109e into main Feb 16, 2022
@joshwlewis joshwlewis deleted the yarn-cache-replace-target branch February 16, 2022 16:09
@joshwlewis
Copy link
Member Author

joshwlewis commented Feb 16, 2022

@edmorley -- You were right, this does not clean up nested caches. I added clean up logic here: 2ec5589.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants