Skip to content

Commit

Permalink
Upgrade to Yarn v3
Browse files Browse the repository at this point in the history
Follow the steps at https://yarnpkg.com/getting-started/migration to upgrade to Yarn v3:

 1. `yarn set version berry`
 2. Edit `.yarnrc.yml` to add `nodeLinker: node-modules`.
 3. Run `yarn install` to migrate lockfile
 4. Update `.gitignore` (see comment)
 5. Update Dockerfile (see Via PRs for more details)

This follows changes in the hypothesis/via repo
(hypothesis/via#1153,
hypothesis/via#1155).
  • Loading branch information
robertknight committed Aug 3, 2023
1 parent 1b7dd09 commit 9ae9a26
Show file tree
Hide file tree
Showing 6 changed files with 10,036 additions and 6,260 deletions.
10 changes: 10 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -34,3 +34,13 @@ mail/
tests/py3-actual-failures.txt

.devdata.env

# See https://yarnpkg.com/getting-started/qa#which-files-should-be-gitignored.
# This is the "If you're not using Zero-Installs" list.
.pnp.*
.yarn/*
!.yarn/patches
!.yarn/plugins
!.yarn/releases
!.yarn/sdks
!.yarn/versions
874 changes: 874 additions & 0 deletions .yarn/releases/yarn-3.6.1.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 @@
nodeLinker: node-modules
yarnPath: .yarn/releases/yarn-3.6.1.cjs
5 changes: 3 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,9 @@ ENV NODE_ENV production

# Install dependencies.
WORKDIR /tmp/frontend-build
COPY package.json yarn.lock ./
RUN yarn install --frozen-lockfile
COPY package.json .yarnrc.yml yarn.lock ./
COPY .yarn ./.yarn
RUN yarn install --immutable

# Build h js/css.
COPY .babelrc gulpfile.mjs rollup.config.mjs ./
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -73,5 +73,6 @@
"prettier": {
"arrowParens": "avoid",
"singleQuote": true
}
},
"packageManager": "yarn@3.6.1"
}
Loading

0 comments on commit 9ae9a26

Please sign in to comment.