syncpack
syncpack copied to clipboard
pnpmOverrides option missing in verison 8.2.4
Description
The --pnpmOverrides options that was added in version 8.0.0 seems to now be missing in version 8.2.4.
Here is the command line output (notice it's also gone from the help text):
$ syncpack list-mismatches --pnpmOverrides
error: unknown option '--pnpmOverrides'
$ syncpack --version
8.2.4
$ syncpack list-mismatches --help
Usage: index [options]
List dependencies which are required by multiple packages, where the version
is not the same across every package.
Options:
-s, --source [pattern] glob pattern for package.json files to read from (default: [])
-f, --filter [pattern] only include dependencies whose name matches this regex
-c, --config <path> path to a syncpack config file
-p, --prod include dependencies
-d, --dev include devDependencies
-P, --peer include peerDependencies
-R, --resolutions include resolutions (yarn)
-o, --overrides include overrides (npm)
-w, --workspace include locally developed package versions
-h, --help display help for command
Examples:
# uses defaults for resolving packages
syncpack list-mismatches
# uses packages defined by --source when provided
syncpack list-mismatches --source "apps/*/package.json"
# multiple globs can be provided like this
syncpack list-mismatches --source "apps/*/package.json" --source "core/*/package.json"
# uses dependencies regular expression defined by --filter when provided
syncpack list-mismatches --filter "typescript|tslint"
# only inspect "devDependencies"
syncpack list-mismatches --dev
# only inspect "devDependencies" and "peerDependencies"
syncpack list-mismatches --dev --peer
Resolving Packages:
1. If --source globs are provided, use those.
2. If using Pnpm Workspaces, read packages from pnpm-workspace.yaml in the root of the project.
3. If using Yarn Workspaces, read workspaces from package.json.
4. If using Lerna, read packages from lerna.json.
5. Default to "package.json" and "packages/*/package.json".
Reference:
globs https://github.com/isaacs/node-glob#glob-primer
lerna.json https://github.com/lerna/lerna#lernajson
Yarn Workspaces https://yarnpkg.com/lang/en/docs/workspaces
Pnpm Workspaces https://pnpm.js.org/en/workspaces
Suggested Solution
Help Needed
~Hey @TxHawks, this was a breaking change in v8. Let me know if you have any more trouble.~
Ignore me, totally misread that. Will take a look.
Thanks!
@JamieMason Can I help with this? Any hint where in the code to look at?
I've been ill since Friday so I've not had chance to look yet.
Hope you feel better soon
Hey Jonathan, I've had a quick look at the tests via the GitHub UI and I think I've seen a problem.
The tests and test scenarios for npm overrides and pnpm overrides seem to have a few small mistakes where they're mixed up. I did one after the other and messed up copy pasting the scaffolding for the tests. Hopefully once that's corrected we should get some failing tests which point to the bug.
This comment is kind of a note to self but If you'd like to give it a try, it is hopefully a case of fixing typos in those 2 tests and scenarios then running npm run test, otherwise I'll get to it in the next week or so.
Released in 8.3.8, thanks a lot.