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

[TEST] Proof of concept: Yarn 3 Upgrade #3594

Draft
wants to merge 3 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -37,3 +37,13 @@ generated-prisma-client
packages/engine-server/prisma/dev.db
dev.db-journal
builds

# Files to ignore when not doing zero-installs
# https://yarnpkg.com/getting-started/qa#which-files-should-be-gitignored
.pnp.*
.yarn/*
!.yarn/patches
!.yarn/plugins
!.yarn/releases
!.yarn/sdks
!.yarn/versions
783 changes: 783 additions & 0 deletions .yarn/releases/yarn-3.2.3.cjs

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions .yarnrc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
yarnPath: .yarn/releases/yarn-3.2.3.cjs
nodeLinker: node-modules
7 changes: 4 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,8 @@
"hooks:pre-push": "node ./hooks/pre-push.js",
"gen:meta": "node ./bootstrap/scripts/genMeta.js",
"backend:updateDendronDeps": "node bootstrap/backend/updateDendronhqDeps.js",
"stash:unstaged": "git stash save -k 'pre-linting-stash'",
"stash:pop": "git stash && git stash pop stash@{1} && git read-tree stash && git stash drop",
"stash:unstaged": "./scripts/stash-unstaged.sh",
"stash:pop": "./scripts/stash-pop.sh",
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This was failing before, I think it's because Yarn uses its own shell parser to run these scripts, and wasn't handling the {} characters properly. Hoisted these scripts out to their own files to workaround it.

yarnpkg/berry#2670

"test": "cross-env LOG_LEVEL=error yarn jest",
"test:cli": "cross-env LOG_LEVEL=error npx jest --selectProjects non-plugin-tests --forceExit",
"test:cli:update-snapshots": "yarn test:cli -u"
Expand Down Expand Up @@ -144,5 +144,6 @@
"typescript": "4.6",
"verdaccio-memory": "^10.0.1",
"webpack": "^5.74.0"
}
},
"packageManager": "[email protected]"
}
4 changes: 2 additions & 2 deletions packages/dendron-cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
"directory": "packages/dendron-cli"
},
"bin": {
"dendron-cli": "./lib/bin/dendron-cli.js",
"dendron": "./lib/bin/dendron-cli.js"
"dendron": "./lib/bin/dendron-cli.js",
"dendron-cli": "./lib/bin/dendron-cli.js"
},
"author": {
"name": "Kevin Lin",
Expand Down
3 changes: 3 additions & 0 deletions scripts/stash-pop.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/usr/bin/env bash

git stash && git stash pop stash@{1} && git read-tree stash && git stash drop
3 changes: 3 additions & 0 deletions scripts/stash-unstaged.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/usr/bin/env bash

git stash save -k 'pre-linting-stash'
Loading