function trimPrefix(version) {
  // https://github.com/microsoft/winget-cli/blob/ae566c7bf21cfcc75be7ec30e4036a30eede8396/src/AppInstallerSharedLib/Versions.cpp#L66
  // If there is a digit before the split character, or no split characters exist, trim off all leading non-digit characters

  const digitPos = version.match(/(\d.*)/)
  const splitPos = version.match(/\./)
  if (digitPos && (splitPos == null || digitPos.index < splitPos.index)) {
    // there is digit before the split character so strip off all leading non-digit characters
    return version.slice(digitPos.index)
  }
  return version
}
Removes all leading non-digit characters from a version number string
if there is a digit before the split character, or no split characters exist.

@param {string} version The version number string to trim
@returns {string} The version number string with all leading non-digit characters removed