code: function toDrupalMajorVersion(version) {
      var regex = /^(\d+)\.\d+\.[x\d+]/;
      var match = version.match(regex)
      if (match) {
        return match[1] + '.x';
      }
  
      return version;
    }
docs: The Drupal update system uses a pre-semver approach of version numbering.
  
  Major versions must be in the form of "8.x", as opposed to other semver
  ranges or version numbers.