_install_get_version_info($version)
Extracts version information from a drupal core version string.
Parameters
string $version: Version info string (e.g., 8.0.0, 8.1.0, 8.0.0-dev, 8.0.0-unstable1, 8.0.0-alpha2, 8.0.0-beta3, and 8.0.0-rc4).
Return value
array Associative array of version info:
major: Major version (e.g., "8").
minor: Minor version (e.g., "0").
patch: Patch version (e.g., "0").
extra: Extra version info (e.g., "alpha2").
extra_text: The text part of "extra" (e.g., "alpha")