tiny bash cleanup, found a fix for bash 3

This commit is contained in:
Harald Hope 2017-07-29 19:59:56 -07:00
parent 2a1c6bed6d
commit e8dabe0b6b

4
inxi
View file

@ -9467,9 +9467,7 @@ get_dev_processed_item()
get_patch_version_string() get_patch_version_string()
{ {
# note: bash 3 does not support: ${SELF_PATCH##+(0)} SELF_PATCH=${SELF_PATCH##*[0]} # strip leading zero(s)
SELF_PATCH=${SELF_PATCH#0} # strip leading zero
SELF_PATCH=${SELF_PATCH#0} # strip leading zero
if [[ -n $SELF_PATCH ]];then if [[ -n $SELF_PATCH ]];then
SELF_PATCH="-$SELF_PATCH" SELF_PATCH="-$SELF_PATCH"