Drop the .XX from OSX version
This commit is contained in:
parent
28f936e03f
commit
9d40beb186
17
neofetch
17
neofetch
|
@ -469,16 +469,17 @@ case "$os" in
|
||||||
|
|
||||||
"Mac OS X")
|
"Mac OS X")
|
||||||
osx_version=$(sw_vers -productVersion)
|
osx_version=$(sw_vers -productVersion)
|
||||||
|
osx_version=${osx_version%.*}
|
||||||
|
|
||||||
case "$osx_version" in
|
case "$osx_version" in
|
||||||
"10.4."*) codename="Mac OS X Tiger" ;;
|
"10.4") codename="Mac OS X Tiger" ;;
|
||||||
"10.5."*) codename="Mac OS X Leopard" ;;
|
"10.5") codename="Mac OS X Leopard" ;;
|
||||||
"10.6."*) codename="Mac OS X Snow Leopard" ;;
|
"10.6") codename="Mac OS X Snow Leopard" ;;
|
||||||
"10.7."*) codename="Mac OS X Lion" ;;
|
"10.7") codename="Mac OS X Lion" ;;
|
||||||
"10.8."*) codename="OS X Mountain Lion" ;;
|
"10.8") codename="OS X Mountain Lion" ;;
|
||||||
"10.9."*) codename="OS X Mavericks" ;;
|
"10.9") codename="OS X Mavericks" ;;
|
||||||
"10.10."*) codename="OS X Yosemite" ;;
|
"10.10") codename="OS X Yosemite" ;;
|
||||||
"10.11."*) codename="OS X El Capitan" ;;
|
"10.11") codename="OS X El Capitan" ;;
|
||||||
*) codename="Mac OS X" ;;
|
*) codename="Mac OS X" ;;
|
||||||
esac
|
esac
|
||||||
distro="$codename $osx_version"
|
distro="$codename $osx_version"
|
||||||
|
|
Reference in New Issue