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

Upgrade to Yarn 4 #8061

Merged
merged 14 commits into from
Sep 11, 2024
Merged

Upgrade to Yarn 4 #8061

merged 14 commits into from
Sep 11, 2024

Conversation

hotzenklotz
Copy link
Member

@hotzenklotz hotzenklotz commented Sep 6, 2024

Updated yarn to version 4 following the offical migration guide.. Except for the .gitignorefile all files were auto-created/auto-updated.

Other changes:

  • Removed some additional yarn installation of the command-JS-package during the SBT asset compilation. The package is already installed as a dev-dependency of the main yarn WK installation.
  • Remove yarn caching from CI. Restore Cache (51s) and Save Cache (2 min) are slower than just yarn install including the download (18s).

Steps to test:

  1. Make sure that node 18+ is installed
  2. Run corepack enable
  3. Run yarn install

Issues:


(Please delete unneeded items, merge only when none are left open)

Copy link
Member Author

Choose a reason for hiding this comment

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

I slightly grouped some of the more obvious ignored files. Only moved stuff around.

**/screenshots/*.diff.png
**/screenshots/*.new.png

# Yarn
Copy link
Member Author

Choose a reason for hiding this comment

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

Added a new yarn group as described in their docs: https://yarnpkg.com/getting-started/qa#which-files-should-be-gitignored

tools/proxy/yarn.lock Outdated Show resolved Hide resolved
@hotzenklotz hotzenklotz self-assigned this Sep 6, 2024
@hotzenklotz hotzenklotz marked this pull request as ready for review September 10, 2024 10:05
@philippotto philippotto changed the title Add Yarn 4 Upgrade to Yarn 4 Sep 10, 2024
Copy link
Member

@philippotto philippotto left a comment

Choose a reason for hiding this comment

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

sweet 🕺

.gitignore Outdated
!.yarn/releases
!.yarn/sdks
!.yarn/versions
tools/proxy/.yarn/install-state.gz
Copy link
Member

Choose a reason for hiding this comment

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

why not add a wildcard à la tools/proxy.yarn/*?

Copy link
Member Author

Choose a reason for hiding this comment

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

Good idea.

@@ -0,0 +1 @@
nodeLinker: node-modules
Copy link
Member

Choose a reason for hiding this comment

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

out of curiousity: did you try other linkers? we don't need to switch in this pr, but I'm wondering if it's complicated.

Copy link
Member Author

Choose a reason for hiding this comment

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

Not yet. I wasn't sure how this works together with webpack/esbuild.

Comment on lines -216 to -221
"resolutions": {
"**/mini-store": "^1.1.0",
"**/redux": "3.7.2",
"**/rc-resize-observer": "^1.4.0",
"**/rc-util": "^5.39.1"
},
Copy link
Member

Choose a reason for hiding this comment

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

are resolutions not supported, anymore? I'm wondering whether the reasons, why we added these initially, are really obsolete now.

Copy link
Member Author

Choose a reason for hiding this comment

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

They were outremoved. I already removed redux, rc-* on the react-18 branch, leaving only mini-store. I cannot find a reference to mini-store either... So this should be fine.

Copy link
Member

@philippotto philippotto left a comment

Choose a reason for hiding this comment

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

really cool! I'm also very happy about the CI speed up 💯

@philippotto philippotto mentioned this pull request Sep 10, 2024
8 tasks
@hotzenklotz hotzenklotz merged commit ede0ecc into master Sep 11, 2024
2 checks passed
@hotzenklotz hotzenklotz deleted the yarn4 branch September 11, 2024 08:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Upgrade yarn to v4
2 participants