small patch for inxi unknown distro, this is a bug fix, so it's a version bump too.

This commit is contained in:
inxi-svn 2011-07-27 23:54:37 +00:00
parent 48ae838480
commit 856ed2bc1b

11
inxi
View file

@ -1,8 +1,8 @@
#!/bin/bash
########################################################################
#### Script Name: inxi
#### version: 1.7.22
#### Date: July 25 2011
#### version: 1.7.23
#### Date: July 27 2011
#### Patch Number: 00
########################################################################
#### SPECIAL THANKS
@ -3407,7 +3407,12 @@ get_distro_data()
fi
## finally, if all else has failed, give up
if [[ -z $distro ]];then
distro='Unknown distro o_O'
if [[ " $DISTROS_DERIVED $DISTROS_PRIMARY " == *" $distro_file "* ]];then
distro=$( sed -E -e 's/[-_]//' -e 's/(release|version)//' <<< $distro_file | sed -E 's/^([a-z])/\u\1/' )
fi
if [[ -z $distro ]];then
distro='Unknown distro o_O'
fi
fi
# this handles an arch bug where /etc/arch-release is empty and /etc/issue is corrupted