Skip to content

Commit

Permalink
add patches to cli template
Browse files Browse the repository at this point in the history
  • Loading branch information
IMax153 committed Sep 10, 2024
1 parent 2a787eb commit 8ea991a
Show file tree
Hide file tree
Showing 2 changed files with 74 additions and 0 deletions.
26 changes: 26 additions & 0 deletions templates/cli/patches/@[email protected]
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
diff --git a/dist/changesets-assemble-release-plan.cjs.js b/dist/changesets-assemble-release-plan.cjs.js
index 60427457c887f2d72168fecec83d79088c68e3a4..b48899c83ca2bc5bfa0cbb65e0c098d5bb65fe3d 100644
--- a/dist/changesets-assemble-release-plan.cjs.js
+++ b/dist/changesets-assemble-release-plan.cjs.js
@@ -189,7 +189,7 @@ function determineDependents({
preInfo,
onlyUpdatePeerDependentsWhenOutOfRange: config.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH.onlyUpdatePeerDependentsWhenOutOfRange
})) {
- type = "major";
+ type = "minor";
} else if ((!releases.has(dependent) || releases.get(dependent).type === "none") && (config.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH.updateInternalDependents === "always" || !semverSatisfies__default["default"](incrementVersion(nextRelease, preInfo), versionRange))) {
switch (depType) {
case "dependencies":
diff --git a/dist/changesets-assemble-release-plan.esm.js b/dist/changesets-assemble-release-plan.esm.js
index f6583cf3f639e1fe4df764a015689dea74127236..2b9dca9f460793596394484457a94a34bcc1d99a 100644
--- a/dist/changesets-assemble-release-plan.esm.js
+++ b/dist/changesets-assemble-release-plan.esm.js
@@ -178,7 +178,7 @@ function determineDependents({
preInfo,
onlyUpdatePeerDependentsWhenOutOfRange: config.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH.onlyUpdatePeerDependentsWhenOutOfRange
})) {
- type = "major";
+ type = "minor";
} else if ((!releases.has(dependent) || releases.get(dependent).type === "none") && (config.___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH.updateInternalDependents === "always" || !semverSatisfies(incrementVersion(nextRelease, preInfo), versionRange))) {
switch (depType) {
case "dependencies":
48 changes: 48 additions & 0 deletions templates/cli/patches/@[email protected]
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
diff --git a/dist/changesets-get-github-info.cjs.js b/dist/changesets-get-github-info.cjs.js
index a74df59f8a5988f458a3476087399f5e6dfe4818..ce5e60ef9916eb0cb76ab1e9dd422abcad752bf6 100644
--- a/dist/changesets-get-github-info.cjs.js
+++ b/dist/changesets-get-github-info.cjs.js
@@ -251,18 +251,13 @@ async function getInfo(request) {
b = new Date(b.mergedAt);
return a > b ? 1 : a < b ? -1 : 0;
})[0] : null;
-
- if (associatedPullRequest) {
- user = associatedPullRequest.author;
- }
-
return {
user: user ? user.login : null,
pull: associatedPullRequest ? associatedPullRequest.number : null,
links: {
commit: `[\`${request.commit.slice(0, 7)}\`](${data.commitUrl})`,
pull: associatedPullRequest ? `[#${associatedPullRequest.number}](${associatedPullRequest.url})` : null,
- user: user ? `[@${user.login}](${user.url})` : null
+ user: user ? `@${user.login}` : null
}
};
}
diff --git a/dist/changesets-get-github-info.esm.js b/dist/changesets-get-github-info.esm.js
index 27e5c972ab1202ff16f5124b471f4bbcc46be2b5..3940a8fe86e10cb46d8ff6436dea1103b1839927 100644
--- a/dist/changesets-get-github-info.esm.js
+++ b/dist/changesets-get-github-info.esm.js
@@ -242,18 +242,13 @@ async function getInfo(request) {
b = new Date(b.mergedAt);
return a > b ? 1 : a < b ? -1 : 0;
})[0] : null;
-
- if (associatedPullRequest) {
- user = associatedPullRequest.author;
- }
-
return {
user: user ? user.login : null,
pull: associatedPullRequest ? associatedPullRequest.number : null,
links: {
commit: `[\`${request.commit.slice(0, 7)}\`](${data.commitUrl})`,
pull: associatedPullRequest ? `[#${associatedPullRequest.number}](${associatedPullRequest.url})` : null,
- user: user ? `[@${user.login}](${user.url})` : null
+ user: user ? `@${user.login}` : null
}
};
}

0 comments on commit 8ea991a

Please sign in to comment.