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

Vendor yarn executable #132

Merged
merged 4 commits into from
Jan 12, 2022
Merged

Vendor yarn executable #132

merged 4 commits into from
Jan 12, 2022

Conversation

Dkendal
Copy link
Contributor

@Dkendal Dkendal commented Jan 11, 2022

Description

Adds a vendored copy of the yarn executable to version control as well as a
config file (.yarnrc.yml) to instruct clients which version to use.

Purpose of this is to ensure that everyone uses the same version, leading to
reproducible builds - and ensures that the project builds properly when mounted
as a submodule of a directory that also has a yarn lock file. In effect this
ensures that this project is built with yarn 1 and treated as it's own root.

Changelog

  • chore: vendor yarn version
  • chore: change git ignore for yarn files
  • chore: "add-target" make target

@@ -0,0 +1 @@
yarnPath: .yarn/releases/yarn-1.23.0-20211220.1904.cjs
Copy link
Contributor

Choose a reason for hiding this comment

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

Apologies for the dumb question, but anyways: This means one needs to have yarn installed globally, then that yarn executable will look at that this file, read the yarnPath key, and just execute (or shell out to) this binary instead, and nothing more?

If this is correct, then devs (and CI I guess) would just install any Yarn version (assuming all versions have the same behavior of reading .yarnrc.yml and reading yarnPath from it)?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yes I believe that is accurate

@Dkendal Dkendal requested a review from mhevery January 12, 2022 19:23
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.

3 participants