@changesets/config
Advanced tools
Comparing version 1.5.0 to 1.6.0
# @changesets/config | ||
## 1.6.0 | ||
### Minor Changes | ||
- [#542](https://github.com/atlassian/changesets/pull/542) [`de2b4a5`](https://github.com/atlassian/changesets/commit/de2b4a5a7b244a37d94625bcb70ecde9dde5b612) Thanks [@Andarist](https://github.com/Andarist)! - A new `updateInternalDependents` experimental option has been added. It can be used to add dependent packages to the release (if they are not already a part of it) with patch bumps. To use it you can add this to your config: | ||
```json | ||
{ | ||
"___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH": { | ||
"updateInternalDependents": "always" | ||
} | ||
} | ||
``` | ||
This option accepts two values - `"always"` and `"out-of-range"` (the latter matches the current default behavior). | ||
### Patch Changes | ||
- Updated dependencies [[`de2b4a5`](https://github.com/atlassian/changesets/commit/de2b4a5a7b244a37d94625bcb70ecde9dde5b612)]: | ||
- @changesets/types@4.0.0 | ||
- @changesets/get-dependents-graph@1.2.1 | ||
## 1.5.0 | ||
@@ -4,0 +26,0 @@ |
@@ -19,3 +19,3 @@ 'use strict'; | ||
name: "@changesets/config", | ||
version: "1.5.0", | ||
version: "1.6.0", | ||
description: "Utilities for reading and parsing Changeset's config", | ||
@@ -25,3 +25,3 @@ main: "dist/config.cjs.js", | ||
license: "MIT", | ||
repository: "https://github.com/changesets/changesets/tree/master/packages/config", | ||
repository: "https://github.com/changesets/changesets/tree/main/packages/config", | ||
files: [ | ||
@@ -33,5 +33,5 @@ "dist", | ||
"@changesets/errors": "^0.1.4", | ||
"@changesets/get-dependents-graph": "^1.2.0", | ||
"@changesets/get-dependents-graph": "^1.2.1", | ||
"@changesets/logger": "^0.0.5", | ||
"@changesets/types": "^3.3.0", | ||
"@changesets/types": "^4.0.0", | ||
"@manypkg/get-packages": "^1.0.1", | ||
@@ -93,2 +93,4 @@ "fs-extra": "^7.0.1", | ||
let parse = (json, packages) => { | ||
var _json$___experimental, _json$___experimental2; | ||
let messages = []; | ||
@@ -190,2 +192,3 @@ let pkgNames = packages.packages.map(({ | ||
onlyUpdatePeerDependentsWhenOutOfRange, | ||
updateInternalDependents, | ||
useCalculatedVersionForSnapshots | ||
@@ -198,2 +201,6 @@ } = json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH; | ||
if (updateInternalDependents !== undefined && !["always", "out-of-range"].includes(updateInternalDependents)) { | ||
messages.push(`The \`updateInternalDependents\` option is set as ${JSON.stringify(updateInternalDependents, null, 2)} but can only be 'always' or 'out-of-range'`); | ||
} | ||
if (useCalculatedVersionForSnapshots !== undefined && typeof useCalculatedVersionForSnapshots !== "boolean") { | ||
@@ -219,2 +226,3 @@ messages.push(`The \`useCalculatedVersionForSnapshots\` option is set as ${JSON.stringify(useCalculatedVersionForSnapshots, null, 2)} when the only valid values are undefined or a boolean`); | ||
onlyUpdatePeerDependentsWhenOutOfRange: json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH === undefined || json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH.onlyUpdatePeerDependentsWhenOutOfRange === undefined ? false : json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH.onlyUpdatePeerDependentsWhenOutOfRange, | ||
updateInternalDependents: (_json$___experimental = (_json$___experimental2 = json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH) === null || _json$___experimental2 === void 0 ? void 0 : _json$___experimental2.updateInternalDependents) !== null && _json$___experimental !== void 0 ? _json$___experimental : "out-of-range", | ||
useCalculatedVersionForSnapshots: json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH === undefined || json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH.useCalculatedVersionForSnapshots === undefined ? false : json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH.useCalculatedVersionForSnapshots | ||
@@ -221,0 +229,0 @@ } |
@@ -17,3 +17,3 @@ "use strict"; | ||
name: "@changesets/config", | ||
version: "1.5.0", | ||
version: "1.6.0", | ||
description: "Utilities for reading and parsing Changeset's config", | ||
@@ -23,9 +23,9 @@ main: "dist/config.cjs.js", | ||
license: "MIT", | ||
repository: "https://github.com/changesets/changesets/tree/master/packages/config", | ||
repository: "https://github.com/changesets/changesets/tree/main/packages/config", | ||
files: [ "dist", "schema.json" ], | ||
dependencies: { | ||
"@changesets/errors": "^0.1.4", | ||
"@changesets/get-dependents-graph": "^1.2.0", | ||
"@changesets/get-dependents-graph": "^1.2.1", | ||
"@changesets/logger": "^0.0.5", | ||
"@changesets/types": "^3.3.0", | ||
"@changesets/types": "^4.0.0", | ||
"@manypkg/get-packages": "^1.0.1", | ||
@@ -69,2 +69,3 @@ "fs-extra": "^7.0.1", | ||
}, parse = (json, packages) => { | ||
var _json$___experimental, _json$___experimental2; | ||
let messages = [], pkgNames = packages.packages.map((({packageJson: packageJson}) => packageJson.name)); | ||
@@ -104,4 +105,5 @@ void 0 === json.changelog || !1 === json.changelog || "string" == typeof json.changelog || isArray(json.changelog) && 2 === json.changelog.length && "string" == typeof json.changelog[0] || messages.push(`The \`changelog\` option is set as ${JSON.stringify(json.changelog, null, 2)} when the only valid values are undefined, a module path(e.g. "@changesets/cli/changelog" or "./some-module") or a tuple with a module path and config for the changelog generator(e.g. ["@changesets/cli/changelog", { someOption: true }])`); | ||
if (void 0 !== json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH) { | ||
const {onlyUpdatePeerDependentsWhenOutOfRange: onlyUpdatePeerDependentsWhenOutOfRange, useCalculatedVersionForSnapshots: useCalculatedVersionForSnapshots} = json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH; | ||
const {onlyUpdatePeerDependentsWhenOutOfRange: onlyUpdatePeerDependentsWhenOutOfRange, updateInternalDependents: updateInternalDependents, useCalculatedVersionForSnapshots: useCalculatedVersionForSnapshots} = json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH; | ||
void 0 !== onlyUpdatePeerDependentsWhenOutOfRange && "boolean" != typeof onlyUpdatePeerDependentsWhenOutOfRange && messages.push(`The \`onlyUpdatePeerDependentsWhenOutOfRange\` option is set as ${JSON.stringify(onlyUpdatePeerDependentsWhenOutOfRange, null, 2)} when the only valid values are undefined or a boolean`), | ||
void 0 === updateInternalDependents || [ "always", "out-of-range" ].includes(updateInternalDependents) || messages.push(`The \`updateInternalDependents\` option is set as ${JSON.stringify(updateInternalDependents, null, 2)} but can only be 'always' or 'out-of-range'`), | ||
void 0 !== useCalculatedVersionForSnapshots && "boolean" != typeof useCalculatedVersionForSnapshots && messages.push(`The \`useCalculatedVersionForSnapshots\` option is set as ${JSON.stringify(useCalculatedVersionForSnapshots, null, 2)} when the only valid values are undefined or a boolean`); | ||
@@ -121,2 +123,3 @@ } | ||
onlyUpdatePeerDependentsWhenOutOfRange: void 0 !== json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH && void 0 !== json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH.onlyUpdatePeerDependentsWhenOutOfRange && json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH.onlyUpdatePeerDependentsWhenOutOfRange, | ||
updateInternalDependents: null !== (_json$___experimental = null === (_json$___experimental2 = json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH) || void 0 === _json$___experimental2 ? void 0 : _json$___experimental2.updateInternalDependents) && void 0 !== _json$___experimental ? _json$___experimental : "out-of-range", | ||
useCalculatedVersionForSnapshots: void 0 !== json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH && void 0 !== json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH.useCalculatedVersionForSnapshots && json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH.useCalculatedVersionForSnapshots | ||
@@ -123,0 +126,0 @@ } |
@@ -10,3 +10,3 @@ import { readJSON } from 'fs-extra'; | ||
name: "@changesets/config", | ||
version: "1.5.0", | ||
version: "1.6.0", | ||
description: "Utilities for reading and parsing Changeset's config", | ||
@@ -16,3 +16,3 @@ main: "dist/config.cjs.js", | ||
license: "MIT", | ||
repository: "https://github.com/changesets/changesets/tree/master/packages/config", | ||
repository: "https://github.com/changesets/changesets/tree/main/packages/config", | ||
files: [ | ||
@@ -24,5 +24,5 @@ "dist", | ||
"@changesets/errors": "^0.1.4", | ||
"@changesets/get-dependents-graph": "^1.2.0", | ||
"@changesets/get-dependents-graph": "^1.2.1", | ||
"@changesets/logger": "^0.0.5", | ||
"@changesets/types": "^3.3.0", | ||
"@changesets/types": "^4.0.0", | ||
"@manypkg/get-packages": "^1.0.1", | ||
@@ -84,2 +84,4 @@ "fs-extra": "^7.0.1", | ||
let parse = (json, packages) => { | ||
var _json$___experimental, _json$___experimental2; | ||
let messages = []; | ||
@@ -181,2 +183,3 @@ let pkgNames = packages.packages.map(({ | ||
onlyUpdatePeerDependentsWhenOutOfRange, | ||
updateInternalDependents, | ||
useCalculatedVersionForSnapshots | ||
@@ -189,2 +192,6 @@ } = json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH; | ||
if (updateInternalDependents !== undefined && !["always", "out-of-range"].includes(updateInternalDependents)) { | ||
messages.push(`The \`updateInternalDependents\` option is set as ${JSON.stringify(updateInternalDependents, null, 2)} but can only be 'always' or 'out-of-range'`); | ||
} | ||
if (useCalculatedVersionForSnapshots !== undefined && typeof useCalculatedVersionForSnapshots !== "boolean") { | ||
@@ -210,2 +217,3 @@ messages.push(`The \`useCalculatedVersionForSnapshots\` option is set as ${JSON.stringify(useCalculatedVersionForSnapshots, null, 2)} when the only valid values are undefined or a boolean`); | ||
onlyUpdatePeerDependentsWhenOutOfRange: json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH === undefined || json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH.onlyUpdatePeerDependentsWhenOutOfRange === undefined ? false : json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH.onlyUpdatePeerDependentsWhenOutOfRange, | ||
updateInternalDependents: (_json$___experimental = (_json$___experimental2 = json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH) === null || _json$___experimental2 === void 0 ? void 0 : _json$___experimental2.updateInternalDependents) !== null && _json$___experimental !== void 0 ? _json$___experimental : "out-of-range", | ||
useCalculatedVersionForSnapshots: json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH === undefined || json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH.useCalculatedVersionForSnapshots === undefined ? false : json.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH.useCalculatedVersionForSnapshots | ||
@@ -212,0 +220,0 @@ } |
{ | ||
"name": "@changesets/config", | ||
"version": "1.5.0", | ||
"version": "1.6.0", | ||
"description": "Utilities for reading and parsing Changeset's config", | ||
@@ -8,3 +8,3 @@ "main": "dist/config.cjs.js", | ||
"license": "MIT", | ||
"repository": "https://github.com/changesets/changesets/tree/master/packages/config", | ||
"repository": "https://github.com/changesets/changesets/tree/main/packages/config", | ||
"files": [ | ||
@@ -16,5 +16,5 @@ "dist", | ||
"@changesets/errors": "^0.1.4", | ||
"@changesets/get-dependents-graph": "^1.2.0", | ||
"@changesets/get-dependents-graph": "^1.2.1", | ||
"@changesets/logger": "^0.0.5", | ||
"@changesets/types": "^3.3.0", | ||
"@changesets/types": "^4.0.0", | ||
"@manypkg/get-packages": "^1.0.1", | ||
@@ -21,0 +21,0 @@ "fs-extra": "^7.0.1", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
49088
655
- Removed@changesets/types@3.3.0(transitive)
Updated@changesets/types@^4.0.0