Skip to content

Commit 1e53719

Browse files
authored
fix: drop stale pnpm@10 pin in amplify.yml (#7342)
1 parent 24fc5ce commit 1e53719

1 file changed

Lines changed: 12 additions & 10 deletions

File tree

amplify.yml

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -112,15 +112,15 @@ applications:
112112
# lives at the repo root; nvm walks up to find it.
113113
- nvm install
114114
- nvm use
115-
# Pin pnpm to the major declared by `package.json#engines.pnpm`
116-
# (currently ^10.16.0). `pnpm@latest` would be non-reproducible —
117-
# a future major could change install behavior without warning.
118-
# When the repo root adds a `packageManager` field to
119-
# `package.json`, corepack will auto-use it and the explicit
120-
# `prepare` line below can be dropped (just `corepack enable`
121-
# would suffice).
115+
# Pin pnpm to the version declared by `package.json#packageManager`
116+
# (currently `pnpm@11.0.8`). With that field present, `corepack
117+
# enable` is sufficient — corepack auto-resolves the pinned
118+
# version on the first pnpm invocation. Do NOT add a
119+
# `corepack prepare pnpm@<major> --activate` line here: a stale
120+
# major (e.g. `@10` left behind after `package.json` bumped to v11)
121+
# silently overrides `packageManager` and produces broken
122+
# workspace bin links (FR-2840 follow-up).
122123
- corepack enable
123-
- corepack prepare pnpm@10 --activate
124124
# Reproducible installs only — never `--no-frozen-lockfile`.
125125
# `pnpm install` from anywhere in the workspace installs the
126126
# entire monorepo by default (it locates the workspace root
@@ -242,8 +242,9 @@ applications:
242242
commands:
243243
- nvm install
244244
- nvm use
245+
# `corepack enable` is sufficient when `package.json#packageManager`
246+
# is set (see the docs entry above for the rationale).
245247
- corepack enable
246-
- corepack prepare pnpm@10 --activate
247248
- pnpm install --frozen-lockfile
248249
build:
249250
commands:
@@ -282,8 +283,9 @@ applications:
282283
commands:
283284
- nvm install
284285
- nvm use
286+
# `corepack enable` is sufficient when `package.json#packageManager`
287+
# is set (see the docs entry above for the rationale).
285288
- corepack enable
286-
- corepack prepare pnpm@10 --activate
287289
- pnpm install --frozen-lockfile
288290
# Relay codegen for both projects, invoked at the
289291
# workspace root via pnpm's `-w` flag so the current

0 commit comments

Comments
 (0)