mirror of
https://github.com/smxi/inxi.git
synced 2025-01-19 08:57:57 +00:00
tiny bash cleanup, found a fix for bash 3
This commit is contained in:
parent
2a1c6bed6d
commit
e8dabe0b6b
4
inxi
4
inxi
|
@ -9467,9 +9467,7 @@ get_dev_processed_item()
|
|||
|
||||
get_patch_version_string()
|
||||
{
|
||||
# note: bash 3 does not support: ${SELF_PATCH##+(0)}
|
||||
SELF_PATCH=${SELF_PATCH#0} # strip leading zero
|
||||
SELF_PATCH=${SELF_PATCH#0} # strip leading zero
|
||||
SELF_PATCH=${SELF_PATCH##*[0]} # strip leading zero(s)
|
||||
|
||||
if [[ -n $SELF_PATCH ]];then
|
||||
SELF_PATCH="-$SELF_PATCH"
|
||||
|
|
Loading…
Reference in a new issue