-
-
Notifications
You must be signed in to change notification settings - Fork 43
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
Sync version in custom package.json properties #112
Comments
Thanks for this @LudovicSterlin, I've had an idea and am just leaving some notes here while I still have it. The internals could be refactored to use this data structure internally, which can't be changed but can be added to:
Users could add their own in
Possible types of
This data could be referenced in version and semver groups etc. |
BREAKING CHANGE: 1. The following options were replaced in syncpack@9.0.0: -p, --prod include dependencies -d, --dev include devDependencies -P, --peer include peerDependencies -R, --resolutions include resolutions (yarn) -o, --overrides include overrides (npm) -O, --pnpmOverrides include overrides (pnpm) -w, --workspace include locally developed package versions Instead use the new --types option like so: --types dev,prod,peer 2. In .syncpackrc, the following options were replaced: "dev": true, "overrides": true, "peer": true, "pnpmOverrides": true, "prod": true, "resolutions": true, "workspace": true, Instead use the new dependencyTypes array like so: "dependencyTypes": ["dev", "prod", "peer"] Closes #112 Closes #113 Co-authored-by: Ludovic Sterlin <ludovic.sterlin@hinfact.com>
BREAKING CHANGE: 1. The following options were replaced in syncpack@9.0.0: -p, --prod include dependencies -d, --dev include devDependencies -P, --peer include peerDependencies -R, --resolutions include resolutions (yarn) -o, --overrides include overrides (npm) -O, --pnpmOverrides include overrides (pnpm) -w, --workspace include locally developed package versions Instead use the new --types option like so: --types dev,prod,peer 2. In .syncpackrc, the following options were replaced: "dev": true, "overrides": true, "peer": true, "pnpmOverrides": true, "prod": true, "resolutions": true, "workspace": true, Instead use the new dependencyTypes array like so: "dependencyTypes": ["dev", "prod", "peer"] Closes #112 Closes #113 Co-authored-by: Ludovic Sterlin <ludovic.sterlin@hinfact.com>
This is now available as of 9.0.0, please let me know if you run into any problems – thanks a lot. |
Description
Sync version in custom
package.json
properties to match the version in(dev/peer/optional)dependencies
.The custom properties can be nested propertyies of package.json.
For example, directus has a utility that creates a
package.json
with adirectus:extension
property like the below:Where the value at
directus:extension.host
is actually a directus versionSuggested Solution
Add a
dependenciesCustomPaths
option in the form of an array of custom dependencies paths each defined by the name of the dependencies it should be associated with and its path in thepackage.json
file.In TypeScript this would result in something like:
This option could be given through the config file, if we take the example from above this would result in a
.syncpackrc.yaml
like below:Help Needed
A bit of help on testing other syncpack features than
list/fix-mismatches
which are the ones I am familiar with.Review of the associated MR -> #113
The text was updated successfully, but these errors were encountered: