Created
July 2, 2019 12:58
-
-
Save nexus166/af6d3dfffdfef897dd2d0f92791e9b0f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| set -x | |
| eval $(< /etc/os-release) | |
| set +x | |
| _os="$(printf '%s' ${ID} | tr '[[:upper:]]' '[[:lower:]]')" | |
| _version="$(printf '%s' "${VERSION}" | awk -F'[()]' '{print tolower($2)}' | cut -d' ' -f1)" | |
| printf '%s:%s' "${_os}" "${_version}" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment