You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit a147da4
Browse filesBrowse the repository at this point in the historyBrowse files
fix(scripts): release helper rejects versions that would move a channel backwards
Preflight only checked the exact version was unused, so a target cut from a dev branch whose version line trails main (dev 2.18.0 vs npm latest 2.19.0) could publish an obsolete version over the channel tip. The preflight now reads npm dist-tags and requires the proposed version to be strictly newer than the channel's current version (semver-ordered, preview channel compared against preview).
console.error(`✗ npm dist-tags response for ${packageName} was not JSON`);
205
+
process.exit(1);
206
+
}
207
+
constcurrent=distTags[channel];
208
+
if(!current)return;// channel not published yet — nothing to regress
209
+
if(compareReleaseVersions(version,current)<=0){
210
+
console.error(`✗ release version ${version} does not move the '${channel}' channel forward (current: ${current}).`);
211
+
console.error("Reconcile the version line first: dev's package.json may trail the latest release; pick a version strictly newer than the channel tip.");
0 commit comments