diff options
-rwxr-xr-x | mk/xe-linux-distribution | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/mk/xe-linux-distribution b/mk/xe-linux-distribution index dccb7f4..b48c511 100755 --- a/mk/xe-linux-distribution +++ b/mk/xe-linux-distribution @@ -286,16 +286,17 @@ identify_kylin() local minor # distro + # NeoKylin Linux Security OS V5.0 (Update8) # NeoKylin Linux Advanced Server release 6.5 (Berryllium) # NeoKylin Linux Advanced Server release 7.0 if [ ! -f "${kylin_release}" ] ; then - return 1 + return 1 fi eval $(sed -rn \ - 's/^NeoKylin Linux Advanced Server release V*([0-9]*)[^0-9]*([0-9]*).*$/distro=neokylin;major=\1;minor=\2;/gp;' \ - "${kylin_release}") + 's/^NeoKylin Linux.*([0-9]+)\.([0-9]+).*$/distro=neokylin;major=\1;minor=\2;/gp;' \ + "${kylin_release}") if [ -z "${major}" -o -z "${distro}" ] ; then return 1 |