mirror of
https://github.com/quickemu-project/quickemu.git
synced 2024-06-07 15:35:26 +02:00
refactor: use LANG and EDITION in list_supported()
This commit is contained in:
parent
7c8db64c1b
commit
ed855c05a7
23
quickget
23
quickget
|
@ -364,26 +364,23 @@ function create_config() {
|
|||
|
||||
function list_supported() {
|
||||
# output OS RELEASE EDITION (usefull for straight testing...)
|
||||
local DL=""
|
||||
local FUNC
|
||||
local OPTION
|
||||
local OS
|
||||
local FUNC=""
|
||||
local OS=""
|
||||
for OS in $(os_support); do
|
||||
case ${OS} in
|
||||
*ubuntu-server*) FUNC="ubuntu-server";;
|
||||
*ubuntu*) FUNC="ubuntu";;
|
||||
*) FUNC="${OS}";;
|
||||
esac
|
||||
FUNC="${OS}"
|
||||
if [[ "${OS}" == *ubuntu* && "${OS}" != "ubuntu-server" ]]; then
|
||||
FUNC="ubuntu"
|
||||
fi
|
||||
for RELEASE in $("releases_${FUNC}" | sed -Ee 's/eol-\S+//g' ); do # hide eol releases
|
||||
# If the OS has an editions_() function, use it.
|
||||
if [[ $(type -t "editions_${OS}") == function ]]; then
|
||||
for OPTION in $(editions_"${OS}"); do
|
||||
echo "${OS} ${RELEASE} ${OPTION}"
|
||||
for EDITION in $(editions_"${OS}"); do
|
||||
echo "${OS} ${RELEASE} ${EDITION}"
|
||||
done
|
||||
elif [[ "${OS}" == "windows"* ]]; then
|
||||
"languages_${OS}"
|
||||
for OPTION in "${LANGS[@]}"; do
|
||||
echo "${OS} ${RELEASE} ${OPTION}"
|
||||
for LANG in "${LANGS[@]}"; do
|
||||
echo "${OS} ${RELEASE} ${LANG}"
|
||||
done
|
||||
else
|
||||
echo "${OS} ${RELEASE}"
|
||||
|
|
Loading…
Reference in New Issue
Block a user