mirror of
https://gitlab.com/amrron/setup-scripts.git
synced 2026-10-17 01:54:00 -04:00
vara os versions
This commit is contained in:
+11
-6
@@ -147,7 +147,7 @@ function noOS_Support() {
|
|||||||
yad --image=$DIR/images/corps-icon.png --center --no-buttons \
|
yad --image=$DIR/images/corps-icon.png --center --no-buttons \
|
||||||
--title "INVALID OS DETECTED" \
|
--title "INVALID OS DETECTED" \
|
||||||
--text "A valid OS was not detected.\n\nThis installer was designed for \
|
--text "A valid OS was not detected.\n\nThis installer was designed for \
|
||||||
Debian based distros; specifically Linux Mint 21.3 / 22" \
|
Debian based distros; specifically Linux Mint 22.1" \
|
||||||
${r} ${c}
|
${r} ${c}
|
||||||
exit 1
|
exit 1
|
||||||
|
|
||||||
@@ -157,10 +157,11 @@ function maybeOS_Support() {
|
|||||||
if (yad --image=$DIR/images/corps-icon.png --center \
|
if (yad --image=$DIR/images/corps-icon.png --center \
|
||||||
--title "Not Supported OS" \
|
--title "Not Supported OS" \
|
||||||
--text "Your OS may be compatible with this installer but has not been \
|
--text "Your OS may be compatible with this installer but has not been \
|
||||||
tested.\n\nThis installer has been tested on Linux Mint 21.3 and 22. It should work on most Debian 10 / 11 based distros. \n\nWould you like to continue anyway?" ${r} ${c}) then
|
tested.\n\nThis installer is currently being tested for operation on Linux Mint 22.1 \n\n \
|
||||||
|
It should work on most Debian 10 / 11 based distros. \n\nWould you like to continue anyway?" ${r} ${c}) then
|
||||||
yad --image=$DIR/images/corps-icon.png --center \
|
yad --image=$DIR/images/corps-icon.png --center \
|
||||||
--title "Not Supported OS" \
|
--title "Not Supported OS" \
|
||||||
--text "::: Did not detect perfectly supported OS but,\n\n \
|
--text "::: Did not detect properly supported OS but,\n\n \
|
||||||
::: Continuing installation at user's own risk..." ${r} ${c} ||
|
::: Continuing installation at user's own risk..." ${r} ${c} ||
|
||||||
{ echo "exiting"; exit 1; }
|
{ echo "exiting"; exit 1; }
|
||||||
else
|
else
|
||||||
@@ -171,6 +172,7 @@ tested.\n\nThis installer has been tested on Linux Mint 21.3 and 22. It should
|
|||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function check_os_support() {
|
||||||
# Compatibility check for OS
|
# Compatibility check for OS
|
||||||
# if lsb_release command is on their system
|
# if lsb_release command is on their system
|
||||||
if hash lsb_release 2>/dev/null; then
|
if hash lsb_release 2>/dev/null; then
|
||||||
@@ -185,15 +187,15 @@ tested.\n\nThis installer has been tested on Linux Mint 21.3 and 22. It should
|
|||||||
VER=$(grep "VERSION_ID" /etc/os-release | awk -F "=" '{print $2}' | tr -d '"')
|
VER=$(grep "VERSION_ID" /etc/os-release | awk -F "=" '{print $2}' | tr -d '"')
|
||||||
declare -A VER_MAP=(["11"]="bullseye" ["10"]="buster" ["9"]="stretch" ["8"]="jessie" ["16.04"]="xenial" \
|
declare -A VER_MAP=(["11"]="bullseye" ["10"]="buster" ["9"]="stretch" ["8"]="jessie" ["16.04"]="xenial" \
|
||||||
["14.04"]="trusty" ["18.04"]="bionic" ["18.10"]="cosmic" ["19.04"]="disco" ["19.10"]="eoan" ["20.04"]="focal" ["18"]="sara" ["18.1"]="serena" \
|
["14.04"]="trusty" ["18.04"]="bionic" ["18.10"]="cosmic" ["19.04"]="disco" ["19.10"]="eoan" ["20.04"]="focal" ["18"]="sara" ["18.1"]="serena" \
|
||||||
["18.2"]="sonya" ["18.3"]="sylvia" ["19"]="tara" ["19.1"]="tessa" ["19.2"]="tina" ["19.3"]="tricia" ["20"]="ulyana" ["20.3"]="una" ["21"]="vanessa" ["21.1"]="vera" ["21.2"]="victoria" ["21.3"]="virginia" ["22"]="wilma" ["22.1"]="xia" ["22.2"]="zara" ["22.3"]="zena" ["24.04"]="noble" ["25.04"]="plucky" )
|
["18.2"]="sonya" ["18.3"]="sylvia" ["19"]="tara" ["19.1"]="tessa" ["19.2"]="tina" ["19.3"]="tricia" ["20"]="ulyana" ["20.3"]="una" ["21"]="vanessa" ["21.1"]="vera" ["21.2"]="victoria" ["21.3"]="virginia" ["22"]="wilma" ["22.1"]="xia" ["22.2"]="zara" ["22.3"]="zena" ["24.04"]="noble" ["25.04"]="plucky" ["26.04"]="resolute" )
|
||||||
OSCN=${VER_MAP["${VER}"]}
|
OSCN=${VER_MAP["${VER}"]}
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
case ${PLAT} in
|
case ${PLAT} in
|
||||||
Raspbian|Debian|Linuxmint|Ubuntu)
|
Raspbian|Debian|Linuxmint|Pop|Ubuntu)
|
||||||
case ${OSCN} in
|
case ${OSCN} in
|
||||||
buster|bullseye|una|vanessa|vera|victoria|virginia|wilma|xia|zara|zena|noble|plucky)
|
virginia|wilma|xia|zara|zena|noble|plucky|resolute)
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
maybeOS_Support
|
maybeOS_Support
|
||||||
@@ -206,6 +208,9 @@ tested.\n\nThis installer has been tested on Linux Mint 21.3 and 22. It should
|
|||||||
esac
|
esac
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
#create a finish trap
|
#create a finish trap
|
||||||
function finish {
|
function finish {
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user