11cb0ef41Sopenharmony_ci// Note: this is the semver.org version of the spec that it implements 21cb0ef41Sopenharmony_ci// Not necessarily the package version of this code. 31cb0ef41Sopenharmony_ciconst SEMVER_SPEC_VERSION = '2.0.0' 41cb0ef41Sopenharmony_ci 51cb0ef41Sopenharmony_ciconst MAX_LENGTH = 256 61cb0ef41Sopenharmony_ciconst MAX_SAFE_INTEGER = Number.MAX_SAFE_INTEGER || 71cb0ef41Sopenharmony_ci/* istanbul ignore next */ 9007199254740991 81cb0ef41Sopenharmony_ci 91cb0ef41Sopenharmony_ci// Max safe segment length for coercion. 101cb0ef41Sopenharmony_ciconst MAX_SAFE_COMPONENT_LENGTH = 16 111cb0ef41Sopenharmony_ci 121cb0ef41Sopenharmony_ci// Max safe length for a build identifier. The max length minus 6 characters for 131cb0ef41Sopenharmony_ci// the shortest version with a build 0.0.0+BUILD. 141cb0ef41Sopenharmony_ciconst MAX_SAFE_BUILD_LENGTH = MAX_LENGTH - 6 151cb0ef41Sopenharmony_ci 161cb0ef41Sopenharmony_ciconst RELEASE_TYPES = [ 171cb0ef41Sopenharmony_ci 'major', 181cb0ef41Sopenharmony_ci 'premajor', 191cb0ef41Sopenharmony_ci 'minor', 201cb0ef41Sopenharmony_ci 'preminor', 211cb0ef41Sopenharmony_ci 'patch', 221cb0ef41Sopenharmony_ci 'prepatch', 231cb0ef41Sopenharmony_ci 'prerelease', 241cb0ef41Sopenharmony_ci] 251cb0ef41Sopenharmony_ci 261cb0ef41Sopenharmony_cimodule.exports = { 271cb0ef41Sopenharmony_ci MAX_LENGTH, 281cb0ef41Sopenharmony_ci MAX_SAFE_COMPONENT_LENGTH, 291cb0ef41Sopenharmony_ci MAX_SAFE_BUILD_LENGTH, 301cb0ef41Sopenharmony_ci MAX_SAFE_INTEGER, 311cb0ef41Sopenharmony_ci RELEASE_TYPES, 321cb0ef41Sopenharmony_ci SEMVER_SPEC_VERSION, 331cb0ef41Sopenharmony_ci FLAG_INCLUDE_PRERELEASE: 0b001, 341cb0ef41Sopenharmony_ci FLAG_LOOSE: 0b010, 351cb0ef41Sopenharmony_ci} 36