@carbon/upgrade 11.8.0-rc.0 → 11.9.0-rc.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/cli.js +236 -124
  2. package/package.json +2 -2
package/cli.js CHANGED
@@ -21918,9 +21918,9 @@ var require_safe_buffer = __commonJS({
21918
21918
  }
21919
21919
  });
21920
21920
 
21921
- // ../../node_modules/string_decoder/lib/string_decoder.js
21921
+ // ../../node_modules/bl/node_modules/string_decoder/lib/string_decoder.js
21922
21922
  var require_string_decoder = __commonJS({
21923
- "../../node_modules/string_decoder/lib/string_decoder.js"(exports) {
21923
+ "../../node_modules/bl/node_modules/string_decoder/lib/string_decoder.js"(exports) {
21924
21924
  "use strict";
21925
21925
  var Buffer2 = require_safe_buffer().Buffer;
21926
21926
  var isEncoding = Buffer2.isEncoding || function(encoding) {
@@ -35407,11 +35407,25 @@ var require_constants = __commonJS({
35407
35407
  var MAX_SAFE_INTEGER = Number.MAX_SAFE_INTEGER || /* istanbul ignore next */
35408
35408
  9007199254740991;
35409
35409
  var MAX_SAFE_COMPONENT_LENGTH = 16;
35410
+ var MAX_SAFE_BUILD_LENGTH = MAX_LENGTH - 6;
35411
+ var RELEASE_TYPES = [
35412
+ "major",
35413
+ "premajor",
35414
+ "minor",
35415
+ "preminor",
35416
+ "patch",
35417
+ "prepatch",
35418
+ "prerelease"
35419
+ ];
35410
35420
  module2.exports = {
35411
- SEMVER_SPEC_VERSION,
35412
35421
  MAX_LENGTH,
35422
+ MAX_SAFE_COMPONENT_LENGTH,
35423
+ MAX_SAFE_BUILD_LENGTH,
35413
35424
  MAX_SAFE_INTEGER,
35414
- MAX_SAFE_COMPONENT_LENGTH
35425
+ RELEASE_TYPES,
35426
+ SEMVER_SPEC_VERSION,
35427
+ FLAG_INCLUDE_PRERELEASE: 1,
35428
+ FLAG_LOOSE: 2
35415
35429
  };
35416
35430
  }
35417
35431
  });
@@ -35428,30 +35442,45 @@ var require_debug = __commonJS({
35428
35442
  // ../../node_modules/semver/internal/re.js
35429
35443
  var require_re = __commonJS({
35430
35444
  "../../node_modules/semver/internal/re.js"(exports, module2) {
35431
- var { MAX_SAFE_COMPONENT_LENGTH } = require_constants();
35445
+ var { MAX_SAFE_COMPONENT_LENGTH, MAX_SAFE_BUILD_LENGTH } = require_constants();
35432
35446
  var debug = require_debug();
35433
35447
  exports = module2.exports = {};
35434
35448
  var re = exports.re = [];
35449
+ var safeRe = exports.safeRe = [];
35435
35450
  var src = exports.src = [];
35436
35451
  var t = exports.t = {};
35437
35452
  var R = 0;
35453
+ var LETTERDASHNUMBER = "[a-zA-Z0-9-]";
35454
+ var safeRegexReplacements = [
35455
+ ["\\s", 1],
35456
+ ["\\d", MAX_SAFE_COMPONENT_LENGTH],
35457
+ [LETTERDASHNUMBER, MAX_SAFE_BUILD_LENGTH]
35458
+ ];
35459
+ var makeSafeRegex = (value) => {
35460
+ for (const [token, max] of safeRegexReplacements) {
35461
+ value = value.split(`${token}*`).join(`${token}{0,${max}}`).split(`${token}+`).join(`${token}{1,${max}}`);
35462
+ }
35463
+ return value;
35464
+ };
35438
35465
  var createToken = (name, value, isGlobal) => {
35466
+ const safe = makeSafeRegex(value);
35439
35467
  const index = R++;
35440
35468
  debug(name, index, value);
35441
35469
  t[name] = index;
35442
35470
  src[index] = value;
35443
35471
  re[index] = new RegExp(value, isGlobal ? "g" : void 0);
35472
+ safeRe[index] = new RegExp(safe, isGlobal ? "g" : void 0);
35444
35473
  };
35445
35474
  createToken("NUMERICIDENTIFIER", "0|[1-9]\\d*");
35446
- createToken("NUMERICIDENTIFIERLOOSE", "[0-9]+");
35447
- createToken("NONNUMERICIDENTIFIER", "\\d*[a-zA-Z-][a-zA-Z0-9-]*");
35475
+ createToken("NUMERICIDENTIFIERLOOSE", "\\d+");
35476
+ createToken("NONNUMERICIDENTIFIER", `\\d*[a-zA-Z-]${LETTERDASHNUMBER}*`);
35448
35477
  createToken("MAINVERSION", `(${src[t.NUMERICIDENTIFIER]})\\.(${src[t.NUMERICIDENTIFIER]})\\.(${src[t.NUMERICIDENTIFIER]})`);
35449
35478
  createToken("MAINVERSIONLOOSE", `(${src[t.NUMERICIDENTIFIERLOOSE]})\\.(${src[t.NUMERICIDENTIFIERLOOSE]})\\.(${src[t.NUMERICIDENTIFIERLOOSE]})`);
35450
35479
  createToken("PRERELEASEIDENTIFIER", `(?:${src[t.NUMERICIDENTIFIER]}|${src[t.NONNUMERICIDENTIFIER]})`);
35451
35480
  createToken("PRERELEASEIDENTIFIERLOOSE", `(?:${src[t.NUMERICIDENTIFIERLOOSE]}|${src[t.NONNUMERICIDENTIFIER]})`);
35452
35481
  createToken("PRERELEASE", `(?:-(${src[t.PRERELEASEIDENTIFIER]}(?:\\.${src[t.PRERELEASEIDENTIFIER]})*))`);
35453
35482
  createToken("PRERELEASELOOSE", `(?:-?(${src[t.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${src[t.PRERELEASEIDENTIFIERLOOSE]})*))`);
35454
- createToken("BUILDIDENTIFIER", "[0-9A-Za-z-]+");
35483
+ createToken("BUILDIDENTIFIER", `${LETTERDASHNUMBER}+`);
35455
35484
  createToken("BUILD", `(?:\\+(${src[t.BUILDIDENTIFIER]}(?:\\.${src[t.BUILDIDENTIFIER]})*))`);
35456
35485
  createToken("FULLPLAIN", `v?${src[t.MAINVERSION]}${src[t.PRERELEASE]}?${src[t.BUILD]}?`);
35457
35486
  createToken("FULL", `^${src[t.FULLPLAIN]}$`);
@@ -35491,11 +35520,17 @@ var require_re = __commonJS({
35491
35520
  // ../../node_modules/semver/internal/parse-options.js
35492
35521
  var require_parse_options = __commonJS({
35493
35522
  "../../node_modules/semver/internal/parse-options.js"(exports, module2) {
35494
- var opts = ["includePrerelease", "loose", "rtl"];
35495
- var parseOptions = (options) => !options ? {} : typeof options !== "object" ? { loose: true } : opts.filter((k) => options[k]).reduce((o, k) => {
35496
- o[k] = true;
35497
- return o;
35498
- }, {});
35523
+ var looseOption = Object.freeze({ loose: true });
35524
+ var emptyOpts = Object.freeze({});
35525
+ var parseOptions = (options) => {
35526
+ if (!options) {
35527
+ return emptyOpts;
35528
+ }
35529
+ if (typeof options !== "object") {
35530
+ return looseOption;
35531
+ }
35532
+ return options;
35533
+ };
35499
35534
  module2.exports = parseOptions;
35500
35535
  }
35501
35536
  });
@@ -35526,7 +35561,7 @@ var require_semver = __commonJS({
35526
35561
  "../../node_modules/semver/classes/semver.js"(exports, module2) {
35527
35562
  var debug = require_debug();
35528
35563
  var { MAX_LENGTH, MAX_SAFE_INTEGER } = require_constants();
35529
- var { re, t } = require_re();
35564
+ var { safeRe: re, t } = require_re();
35530
35565
  var parseOptions = require_parse_options();
35531
35566
  var { compareIdentifiers } = require_identifiers();
35532
35567
  var SemVer = class _SemVer {
@@ -35539,7 +35574,7 @@ var require_semver = __commonJS({
35539
35574
  version = version.version;
35540
35575
  }
35541
35576
  } else if (typeof version !== "string") {
35542
- throw new TypeError(`Invalid Version: ${version}`);
35577
+ throw new TypeError(`Invalid version. Must be a string. Got type "${typeof version}".`);
35543
35578
  }
35544
35579
  if (version.length > MAX_LENGTH) {
35545
35580
  throw new TypeError(
@@ -35665,31 +35700,31 @@ var require_semver = __commonJS({
35665
35700
  }
35666
35701
  // preminor will bump the version up to the next minor release, and immediately
35667
35702
  // down to pre-release. premajor and prepatch work the same way.
35668
- inc(release, identifier) {
35703
+ inc(release, identifier, identifierBase) {
35669
35704
  switch (release) {
35670
35705
  case "premajor":
35671
35706
  this.prerelease.length = 0;
35672
35707
  this.patch = 0;
35673
35708
  this.minor = 0;
35674
35709
  this.major++;
35675
- this.inc("pre", identifier);
35710
+ this.inc("pre", identifier, identifierBase);
35676
35711
  break;
35677
35712
  case "preminor":
35678
35713
  this.prerelease.length = 0;
35679
35714
  this.patch = 0;
35680
35715
  this.minor++;
35681
- this.inc("pre", identifier);
35716
+ this.inc("pre", identifier, identifierBase);
35682
35717
  break;
35683
35718
  case "prepatch":
35684
35719
  this.prerelease.length = 0;
35685
- this.inc("patch", identifier);
35686
- this.inc("pre", identifier);
35720
+ this.inc("patch", identifier, identifierBase);
35721
+ this.inc("pre", identifier, identifierBase);
35687
35722
  break;
35688
35723
  case "prerelease":
35689
35724
  if (this.prerelease.length === 0) {
35690
- this.inc("patch", identifier);
35725
+ this.inc("patch", identifier, identifierBase);
35691
35726
  }
35692
- this.inc("pre", identifier);
35727
+ this.inc("pre", identifier, identifierBase);
35693
35728
  break;
35694
35729
  case "major":
35695
35730
  if (this.minor !== 0 || this.patch !== 0 || this.prerelease.length === 0) {
@@ -35712,9 +35747,13 @@ var require_semver = __commonJS({
35712
35747
  }
35713
35748
  this.prerelease = [];
35714
35749
  break;
35715
- case "pre":
35750
+ case "pre": {
35751
+ const base = Number(identifierBase) ? 1 : 0;
35752
+ if (!identifier && identifierBase === false) {
35753
+ throw new Error("invalid increment argument: identifier is empty");
35754
+ }
35716
35755
  if (this.prerelease.length === 0) {
35717
- this.prerelease = [0];
35756
+ this.prerelease = [base];
35718
35757
  } else {
35719
35758
  let i = this.prerelease.length;
35720
35759
  while (--i >= 0) {
@@ -35724,24 +35763,34 @@ var require_semver = __commonJS({
35724
35763
  }
35725
35764
  }
35726
35765
  if (i === -1) {
35727
- this.prerelease.push(0);
35766
+ if (identifier === this.prerelease.join(".") && identifierBase === false) {
35767
+ throw new Error("invalid increment argument: identifier already exists");
35768
+ }
35769
+ this.prerelease.push(base);
35728
35770
  }
35729
35771
  }
35730
35772
  if (identifier) {
35773
+ let prerelease = [identifier, base];
35774
+ if (identifierBase === false) {
35775
+ prerelease = [identifier];
35776
+ }
35731
35777
  if (compareIdentifiers(this.prerelease[0], identifier) === 0) {
35732
35778
  if (isNaN(this.prerelease[1])) {
35733
- this.prerelease = [identifier, 0];
35779
+ this.prerelease = prerelease;
35734
35780
  }
35735
35781
  } else {
35736
- this.prerelease = [identifier, 0];
35782
+ this.prerelease = prerelease;
35737
35783
  }
35738
35784
  }
35739
35785
  break;
35786
+ }
35740
35787
  default:
35741
35788
  throw new Error(`invalid increment argument: ${release}`);
35742
35789
  }
35743
- this.format();
35744
- this.raw = this.version;
35790
+ this.raw = this.format();
35791
+ if (this.build.length) {
35792
+ this.raw += `+${this.build.join(".")}`;
35793
+ }
35745
35794
  return this;
35746
35795
  }
35747
35796
  };
@@ -35752,29 +35801,18 @@ var require_semver = __commonJS({
35752
35801
  // ../../node_modules/semver/functions/parse.js
35753
35802
  var require_parse2 = __commonJS({
35754
35803
  "../../node_modules/semver/functions/parse.js"(exports, module2) {
35755
- var { MAX_LENGTH } = require_constants();
35756
- var { re, t } = require_re();
35757
35804
  var SemVer = require_semver();
35758
- var parseOptions = require_parse_options();
35759
- var parse = (version, options) => {
35760
- options = parseOptions(options);
35805
+ var parse = (version, options, throwErrors = false) => {
35761
35806
  if (version instanceof SemVer) {
35762
35807
  return version;
35763
35808
  }
35764
- if (typeof version !== "string") {
35765
- return null;
35766
- }
35767
- if (version.length > MAX_LENGTH) {
35768
- return null;
35769
- }
35770
- const r = options.loose ? re[t.LOOSE] : re[t.FULL];
35771
- if (!r.test(version)) {
35772
- return null;
35773
- }
35774
35809
  try {
35775
35810
  return new SemVer(version, options);
35776
35811
  } catch (er) {
35777
- return null;
35812
+ if (!throwErrors) {
35813
+ return null;
35814
+ }
35815
+ throw er;
35778
35816
  }
35779
35817
  };
35780
35818
  module2.exports = parse;
@@ -35809,8 +35847,9 @@ var require_clean = __commonJS({
35809
35847
  var require_inc = __commonJS({
35810
35848
  "../../node_modules/semver/functions/inc.js"(exports, module2) {
35811
35849
  var SemVer = require_semver();
35812
- var inc = (version, release, options, identifier) => {
35850
+ var inc = (version, release, options, identifier, identifierBase) => {
35813
35851
  if (typeof options === "string") {
35852
+ identifierBase = identifier;
35814
35853
  identifier = options;
35815
35854
  options = void 0;
35816
35855
  }
@@ -35818,7 +35857,7 @@ var require_inc = __commonJS({
35818
35857
  return new SemVer(
35819
35858
  version instanceof SemVer ? version.version : version,
35820
35859
  options
35821
- ).inc(release, identifier).version;
35860
+ ).inc(release, identifier, identifierBase).version;
35822
35861
  } catch (er) {
35823
35862
  return null;
35824
35863
  }
@@ -35827,47 +35866,45 @@ var require_inc = __commonJS({
35827
35866
  }
35828
35867
  });
35829
35868
 
35830
- // ../../node_modules/semver/functions/compare.js
35831
- var require_compare = __commonJS({
35832
- "../../node_modules/semver/functions/compare.js"(exports, module2) {
35833
- var SemVer = require_semver();
35834
- var compare = (a, b, loose) => new SemVer(a, loose).compare(new SemVer(b, loose));
35835
- module2.exports = compare;
35836
- }
35837
- });
35838
-
35839
- // ../../node_modules/semver/functions/eq.js
35840
- var require_eq2 = __commonJS({
35841
- "../../node_modules/semver/functions/eq.js"(exports, module2) {
35842
- var compare = require_compare();
35843
- var eq = (a, b, loose) => compare(a, b, loose) === 0;
35844
- module2.exports = eq;
35845
- }
35846
- });
35847
-
35848
35869
  // ../../node_modules/semver/functions/diff.js
35849
35870
  var require_diff = __commonJS({
35850
35871
  "../../node_modules/semver/functions/diff.js"(exports, module2) {
35851
35872
  var parse = require_parse2();
35852
- var eq = require_eq2();
35853
35873
  var diff2 = (version1, version2) => {
35854
- if (eq(version1, version2)) {
35874
+ const v1 = parse(version1, null, true);
35875
+ const v2 = parse(version2, null, true);
35876
+ const comparison = v1.compare(v2);
35877
+ if (comparison === 0) {
35855
35878
  return null;
35856
- } else {
35857
- const v1 = parse(version1);
35858
- const v2 = parse(version2);
35859
- const hasPre = v1.prerelease.length || v2.prerelease.length;
35860
- const prefix = hasPre ? "pre" : "";
35861
- const defaultResult = hasPre ? "prerelease" : "";
35862
- for (const key in v1) {
35863
- if (key === "major" || key === "minor" || key === "patch") {
35864
- if (v1[key] !== v2[key]) {
35865
- return prefix + key;
35866
- }
35867
- }
35879
+ }
35880
+ const v1Higher = comparison > 0;
35881
+ const highVersion = v1Higher ? v1 : v2;
35882
+ const lowVersion = v1Higher ? v2 : v1;
35883
+ const highHasPre = !!highVersion.prerelease.length;
35884
+ const lowHasPre = !!lowVersion.prerelease.length;
35885
+ if (lowHasPre && !highHasPre) {
35886
+ if (!lowVersion.patch && !lowVersion.minor) {
35887
+ return "major";
35888
+ }
35889
+ if (highVersion.patch) {
35890
+ return "patch";
35891
+ }
35892
+ if (highVersion.minor) {
35893
+ return "minor";
35868
35894
  }
35869
- return defaultResult;
35895
+ return "major";
35896
+ }
35897
+ const prefix = highHasPre ? "pre" : "";
35898
+ if (v1.major !== v2.major) {
35899
+ return prefix + "major";
35900
+ }
35901
+ if (v1.minor !== v2.minor) {
35902
+ return prefix + "minor";
35870
35903
  }
35904
+ if (v1.patch !== v2.patch) {
35905
+ return prefix + "patch";
35906
+ }
35907
+ return "prerelease";
35871
35908
  };
35872
35909
  module2.exports = diff2;
35873
35910
  }
@@ -35912,6 +35949,15 @@ var require_prerelease = __commonJS({
35912
35949
  }
35913
35950
  });
35914
35951
 
35952
+ // ../../node_modules/semver/functions/compare.js
35953
+ var require_compare = __commonJS({
35954
+ "../../node_modules/semver/functions/compare.js"(exports, module2) {
35955
+ var SemVer = require_semver();
35956
+ var compare = (a, b, loose) => new SemVer(a, loose).compare(new SemVer(b, loose));
35957
+ module2.exports = compare;
35958
+ }
35959
+ });
35960
+
35915
35961
  // ../../node_modules/semver/functions/rcompare.js
35916
35962
  var require_rcompare = __commonJS({
35917
35963
  "../../node_modules/semver/functions/rcompare.js"(exports, module2) {
@@ -35979,6 +36025,15 @@ var require_lt = __commonJS({
35979
36025
  }
35980
36026
  });
35981
36027
 
36028
+ // ../../node_modules/semver/functions/eq.js
36029
+ var require_eq2 = __commonJS({
36030
+ "../../node_modules/semver/functions/eq.js"(exports, module2) {
36031
+ var compare = require_compare();
36032
+ var eq = (a, b, loose) => compare(a, b, loose) === 0;
36033
+ module2.exports = eq;
36034
+ }
36035
+ });
36036
+
35982
36037
  // ../../node_modules/semver/functions/neq.js
35983
36038
  var require_neq = __commonJS({
35984
36039
  "../../node_modules/semver/functions/neq.js"(exports, module2) {
@@ -36060,7 +36115,7 @@ var require_coerce = __commonJS({
36060
36115
  "../../node_modules/semver/functions/coerce.js"(exports, module2) {
36061
36116
  var SemVer = require_semver();
36062
36117
  var parse = require_parse2();
36063
- var { re, t } = require_re();
36118
+ var { safeRe: re, t } = require_re();
36064
36119
  var coerce = (version, options) => {
36065
36120
  if (version instanceof SemVer) {
36066
36121
  return version;
@@ -36477,9 +36532,9 @@ var require_yallist2 = __commonJS({
36477
36532
  }
36478
36533
  });
36479
36534
 
36480
- // ../../node_modules/lru-cache/index.js
36535
+ // ../../node_modules/semver/node_modules/lru-cache/index.js
36481
36536
  var require_lru_cache2 = __commonJS({
36482
- "../../node_modules/lru-cache/index.js"(exports, module2) {
36537
+ "../../node_modules/semver/node_modules/lru-cache/index.js"(exports, module2) {
36483
36538
  "use strict";
36484
36539
  var Yallist = require_yallist2();
36485
36540
  var MAX = Symbol("max");
@@ -36769,10 +36824,10 @@ var require_range2 = __commonJS({
36769
36824
  this.options = options;
36770
36825
  this.loose = !!options.loose;
36771
36826
  this.includePrerelease = !!options.includePrerelease;
36772
- this.raw = range;
36773
- this.set = range.split("||").map((r) => this.parseRange(r.trim())).filter((c) => c.length);
36827
+ this.raw = range.trim().split(/\s+/).join(" ");
36828
+ this.set = this.raw.split("||").map((r) => this.parseRange(r)).filter((c) => c.length);
36774
36829
  if (!this.set.length) {
36775
- throw new TypeError(`Invalid SemVer Range: ${range}`);
36830
+ throw new TypeError(`Invalid SemVer Range: ${this.raw}`);
36776
36831
  }
36777
36832
  if (this.set.length > 1) {
36778
36833
  const first = this.set[0];
@@ -36791,18 +36846,15 @@ var require_range2 = __commonJS({
36791
36846
  this.format();
36792
36847
  }
36793
36848
  format() {
36794
- this.range = this.set.map((comps) => {
36795
- return comps.join(" ").trim();
36796
- }).join("||").trim();
36849
+ this.range = this.set.map((comps) => comps.join(" ").trim()).join("||").trim();
36797
36850
  return this.range;
36798
36851
  }
36799
36852
  toString() {
36800
36853
  return this.range;
36801
36854
  }
36802
36855
  parseRange(range) {
36803
- range = range.trim();
36804
- const memoOpts = Object.keys(this.options).join(",");
36805
- const memoKey = `parseRange:${memoOpts}:${range}`;
36856
+ const memoOpts = (this.options.includePrerelease && FLAG_INCLUDE_PRERELEASE) | (this.options.loose && FLAG_LOOSE);
36857
+ const memoKey = memoOpts + ":" + range;
36806
36858
  const cached = cache.get(memoKey);
36807
36859
  if (cached) {
36808
36860
  return cached;
@@ -36814,8 +36866,9 @@ var require_range2 = __commonJS({
36814
36866
  range = range.replace(re[t.COMPARATORTRIM], comparatorTrimReplace);
36815
36867
  debug("comparator trim", range);
36816
36868
  range = range.replace(re[t.TILDETRIM], tildeTrimReplace);
36869
+ debug("tilde trim", range);
36817
36870
  range = range.replace(re[t.CARETTRIM], caretTrimReplace);
36818
- range = range.split(/\s+/).join(" ");
36871
+ debug("caret trim", range);
36819
36872
  let rangeList = range.split(" ").map((comp) => parseComparator(comp, this.options)).join(" ").split(/\s+/).map((comp) => replaceGTE0(comp, this.options));
36820
36873
  if (loose) {
36821
36874
  rangeList = rangeList.filter((comp) => {
@@ -36881,12 +36934,13 @@ var require_range2 = __commonJS({
36881
36934
  var debug = require_debug();
36882
36935
  var SemVer = require_semver();
36883
36936
  var {
36884
- re,
36937
+ safeRe: re,
36885
36938
  t,
36886
36939
  comparatorTrimReplace,
36887
36940
  tildeTrimReplace,
36888
36941
  caretTrimReplace
36889
36942
  } = require_re();
36943
+ var { FLAG_INCLUDE_PRERELEASE, FLAG_LOOSE } = require_constants();
36890
36944
  var isNullSet = (c) => c.value === "<0.0.0-0";
36891
36945
  var isAny = (c) => c.value === "";
36892
36946
  var isSatisfiable = (comparators, options) => {
@@ -36914,9 +36968,9 @@ var require_range2 = __commonJS({
36914
36968
  return comp;
36915
36969
  };
36916
36970
  var isX = (id) => !id || id.toLowerCase() === "x" || id === "*";
36917
- var replaceTildes = (comp, options) => comp.trim().split(/\s+/).map((c) => {
36918
- return replaceTilde(c, options);
36919
- }).join(" ");
36971
+ var replaceTildes = (comp, options) => {
36972
+ return comp.trim().split(/\s+/).map((c) => replaceTilde(c, options)).join(" ");
36973
+ };
36920
36974
  var replaceTilde = (comp, options) => {
36921
36975
  const r = options.loose ? re[t.TILDELOOSE] : re[t.TILDE];
36922
36976
  return comp.replace(r, (_, M, m, p, pr) => {
@@ -36938,9 +36992,9 @@ var require_range2 = __commonJS({
36938
36992
  return ret;
36939
36993
  });
36940
36994
  };
36941
- var replaceCarets = (comp, options) => comp.trim().split(/\s+/).map((c) => {
36942
- return replaceCaret(c, options);
36943
- }).join(" ");
36995
+ var replaceCarets = (comp, options) => {
36996
+ return comp.trim().split(/\s+/).map((c) => replaceCaret(c, options)).join(" ");
36997
+ };
36944
36998
  var replaceCaret = (comp, options) => {
36945
36999
  debug("caret", comp, options);
36946
37000
  const r = options.loose ? re[t.CARETLOOSE] : re[t.CARET];
@@ -36987,9 +37041,7 @@ var require_range2 = __commonJS({
36987
37041
  };
36988
37042
  var replaceXRanges = (comp, options) => {
36989
37043
  debug("replaceXRanges", comp, options);
36990
- return comp.split(/\s+/).map((c) => {
36991
- return replaceXRange(c, options);
36992
- }).join(" ");
37044
+ return comp.split(/\s+/).map((c) => replaceXRange(c, options)).join(" ");
36993
37045
  };
36994
37046
  var replaceXRange = (comp, options) => {
36995
37047
  comp = comp.trim();
@@ -37124,6 +37176,7 @@ var require_comparator = __commonJS({
37124
37176
  comp = comp.value;
37125
37177
  }
37126
37178
  }
37179
+ comp = comp.trim().split(/\s+/).join(" ");
37127
37180
  debug("comparator", comp, options);
37128
37181
  this.options = options;
37129
37182
  this.loose = !!options.loose;
@@ -37172,12 +37225,6 @@ var require_comparator = __commonJS({
37172
37225
  if (!(comp instanceof _Comparator)) {
37173
37226
  throw new TypeError("a Comparator is required");
37174
37227
  }
37175
- if (!options || typeof options !== "object") {
37176
- options = {
37177
- loose: !!options,
37178
- includePrerelease: false
37179
- };
37180
- }
37181
37228
  if (this.operator === "") {
37182
37229
  if (this.value === "") {
37183
37230
  return true;
@@ -37189,18 +37236,34 @@ var require_comparator = __commonJS({
37189
37236
  }
37190
37237
  return new Range(this.value, options).test(comp.semver);
37191
37238
  }
37192
- const sameDirectionIncreasing = (this.operator === ">=" || this.operator === ">") && (comp.operator === ">=" || comp.operator === ">");
37193
- const sameDirectionDecreasing = (this.operator === "<=" || this.operator === "<") && (comp.operator === "<=" || comp.operator === "<");
37194
- const sameSemVer = this.semver.version === comp.semver.version;
37195
- const differentDirectionsInclusive = (this.operator === ">=" || this.operator === "<=") && (comp.operator === ">=" || comp.operator === "<=");
37196
- const oppositeDirectionsLessThan = cmp(this.semver, "<", comp.semver, options) && (this.operator === ">=" || this.operator === ">") && (comp.operator === "<=" || comp.operator === "<");
37197
- const oppositeDirectionsGreaterThan = cmp(this.semver, ">", comp.semver, options) && (this.operator === "<=" || this.operator === "<") && (comp.operator === ">=" || comp.operator === ">");
37198
- return sameDirectionIncreasing || sameDirectionDecreasing || sameSemVer && differentDirectionsInclusive || oppositeDirectionsLessThan || oppositeDirectionsGreaterThan;
37239
+ options = parseOptions(options);
37240
+ if (options.includePrerelease && (this.value === "<0.0.0-0" || comp.value === "<0.0.0-0")) {
37241
+ return false;
37242
+ }
37243
+ if (!options.includePrerelease && (this.value.startsWith("<0.0.0") || comp.value.startsWith("<0.0.0"))) {
37244
+ return false;
37245
+ }
37246
+ if (this.operator.startsWith(">") && comp.operator.startsWith(">")) {
37247
+ return true;
37248
+ }
37249
+ if (this.operator.startsWith("<") && comp.operator.startsWith("<")) {
37250
+ return true;
37251
+ }
37252
+ if (this.semver.version === comp.semver.version && this.operator.includes("=") && comp.operator.includes("=")) {
37253
+ return true;
37254
+ }
37255
+ if (cmp(this.semver, "<", comp.semver, options) && this.operator.startsWith(">") && comp.operator.startsWith("<")) {
37256
+ return true;
37257
+ }
37258
+ if (cmp(this.semver, ">", comp.semver, options) && this.operator.startsWith("<") && comp.operator.startsWith(">")) {
37259
+ return true;
37260
+ }
37261
+ return false;
37199
37262
  }
37200
37263
  };
37201
37264
  module2.exports = Comparator;
37202
37265
  var parseOptions = require_parse_options();
37203
- var { re, t } = require_re();
37266
+ var { safeRe: re, t } = require_re();
37204
37267
  var cmp = require_cmp();
37205
37268
  var debug = require_debug();
37206
37269
  var SemVer = require_semver();
@@ -37453,7 +37516,7 @@ var require_intersects = __commonJS({
37453
37516
  var intersects = (r1, r2, options) => {
37454
37517
  r1 = new Range(r1, options);
37455
37518
  r2 = new Range(r2, options);
37456
- return r1.intersects(r2);
37519
+ return r1.intersects(r2, options);
37457
37520
  };
37458
37521
  module2.exports = intersects;
37459
37522
  }
@@ -37538,6 +37601,8 @@ var require_subset = __commonJS({
37538
37601
  }
37539
37602
  return true;
37540
37603
  };
37604
+ var minimumVersionWithPreRelease = [new Comparator(">=0.0.0-0")];
37605
+ var minimumVersion = [new Comparator(">=0.0.0")];
37541
37606
  var simpleSubset = (sub, dom, options) => {
37542
37607
  if (sub === dom) {
37543
37608
  return true;
@@ -37546,16 +37611,16 @@ var require_subset = __commonJS({
37546
37611
  if (dom.length === 1 && dom[0].semver === ANY) {
37547
37612
  return true;
37548
37613
  } else if (options.includePrerelease) {
37549
- sub = [new Comparator(">=0.0.0-0")];
37614
+ sub = minimumVersionWithPreRelease;
37550
37615
  } else {
37551
- sub = [new Comparator(">=0.0.0")];
37616
+ sub = minimumVersion;
37552
37617
  }
37553
37618
  }
37554
37619
  if (dom.length === 1 && dom[0].semver === ANY) {
37555
37620
  if (options.includePrerelease) {
37556
37621
  return true;
37557
37622
  } else {
37558
- dom = [new Comparator(">=0.0.0")];
37623
+ dom = minimumVersion;
37559
37624
  }
37560
37625
  }
37561
37626
  const eqSet = /* @__PURE__ */ new Set();
@@ -37755,6 +37820,7 @@ var require_semver2 = __commonJS({
37755
37820
  src: internalRe.src,
37756
37821
  tokens: internalRe.t,
37757
37822
  SEMVER_SPEC_VERSION: constants.SEMVER_SPEC_VERSION,
37823
+ RELEASE_TYPES: constants.RELEASE_TYPES,
37758
37824
  compareIdentifiers: identifiers.compareIdentifiers,
37759
37825
  rcompareIdentifiers: identifiers.rcompareIdentifiers
37760
37826
  };
@@ -49828,9 +49894,9 @@ ${difference}`;
49828
49894
  }
49829
49895
  });
49830
49896
 
49831
- // ../../node_modules/yargs/node_modules/y18n/build/index.cjs
49897
+ // ../../node_modules/y18n/build/index.cjs
49832
49898
  var require_build5 = __commonJS({
49833
- "../../node_modules/yargs/node_modules/y18n/build/index.cjs"(exports, module2) {
49899
+ "../../node_modules/y18n/build/index.cjs"(exports, module2) {
49834
49900
  "use strict";
49835
49901
  var fs2 = require("fs");
49836
49902
  var util = require("util");
@@ -53904,6 +53970,52 @@ var upgrades = [
53904
53970
  });
53905
53971
  }
53906
53972
  },
53973
+ {
53974
+ name: "size-prop-update",
53975
+ description: "Updates xl sized components to lg",
53976
+ migrate: async (options) => {
53977
+ const transform = import_path2.default.join(TRANSFORM_DIR, "size-prop-update.js");
53978
+ const paths = Array.isArray(options.paths) && options.paths.length > 0 ? options.paths : await (0, import_fast_glob2.default)(["**/*.js", "**/*.jsx"], {
53979
+ cwd: options.workspaceDir,
53980
+ ignore: [
53981
+ "**/es/**",
53982
+ "**/lib/**",
53983
+ "**/umd/**",
53984
+ "**/node_modules/**",
53985
+ "**/storybook-static/**"
53986
+ ]
53987
+ });
53988
+ await run2({
53989
+ dry: !options.write,
53990
+ transform,
53991
+ paths,
53992
+ verbose: options.verbose
53993
+ });
53994
+ }
53995
+ },
53996
+ {
53997
+ name: "small-to-size-prop",
53998
+ description: 'Update usage of small prop to size="sm"',
53999
+ migrate: async (options) => {
54000
+ const transform = import_path2.default.join(TRANSFORM_DIR, "small-to-size-prop.js");
54001
+ const paths = Array.isArray(options.paths) && options.paths.length > 0 ? options.paths : await (0, import_fast_glob2.default)(["**/*.js", "**/*.jsx"], {
54002
+ cwd: options.workspaceDir,
54003
+ ignore: [
54004
+ "**/es/**",
54005
+ "**/lib/**",
54006
+ "**/umd/**",
54007
+ "**/node_modules/**",
54008
+ "**/storybook-static/**"
54009
+ ]
54010
+ });
54011
+ await run2({
54012
+ dry: !options.write,
54013
+ transform,
54014
+ paths,
54015
+ verbose: options.verbose
54016
+ });
54017
+ }
54018
+ },
53907
54019
  {
53908
54020
  name: "update-carbon-components-react-import-to-scoped",
53909
54021
  description: "Rewrites imports from `carbon-components-react` to `@carbon/react`",
@@ -53957,7 +54069,7 @@ var upgrades = [
53957
54069
  var package_default = {
53958
54070
  name: "@carbon/upgrade",
53959
54071
  description: "A tool for upgrading Carbon versions",
53960
- version: "11.8.0-rc.0",
54072
+ version: "11.9.0-rc.0",
53961
54073
  license: "Apache-2.0",
53962
54074
  bin: {
53963
54075
  "carbon-upgrade": "./bin/carbon-upgrade.js"
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@carbon/upgrade",
3
3
  "description": "A tool for upgrading Carbon versions",
4
- "version": "11.8.0-rc.0",
4
+ "version": "11.9.0-rc.0",
5
5
  "license": "Apache-2.0",
6
6
  "bin": {
7
7
  "carbon-upgrade": "./bin/carbon-upgrade.js"
@@ -57,5 +57,5 @@
57
57
  "dependencies": {
58
58
  "jscodeshift": "^0.13.1"
59
59
  },
60
- "gitHead": "fe40fbf428231bd35f6bc8cc871ea09c7afa5051"
60
+ "gitHead": "b9e28c4e35eeddf4ecc3261630a8f3fecc7012d4"
61
61
  }