Move config to..

This commit is contained in:
zenobit 2025-02-18 03:31:41 +01:00
parent 945118746a
commit 0be6fbd65e
2 changed files with 16 additions and 15 deletions

View File

@ -5,6 +5,7 @@ BASEDOF="-"
HOMEPAGE="https://freedos.org"
DESCRIPTION="DOS-compatible operating system that you can use to play classic DOS games, run legacy business software, or develop embedded systems"
CREDENTIALS="-"
GUEST="freedos"
function releases_() {
echo 1.3 1.2
@ -22,3 +23,18 @@ function get_() {
esac
echo "${URL}/${ISO} ${HASH}"
}
function distro_specific() {
if [[ ${ISO} = *".zip"* ]]; then
unzip -qo "${VM_PATH}/${ISO}" -d "${VM_PATH}"
rm -f "${VM_PATH}/${ISO}"
ISO="$(ls -1 "${VM_PATH}/"*.iso)"
ISO="$(basename "${ISO}")"
fi
}
function specific_tweaks() {
echo "boot=\"legacy\"" >> "${CONF_FILE}"
echo "disk_size=\"4G\"" >> "${CONF_FILE}"
echo "ram=\"256M\"" >> "${CONF_FILE}"
}

View File

@ -582,9 +582,6 @@ function make_vm_config() {
haiku)
GUEST="haiku"
IMAGE_TYPE="iso";;
freedos)
GUEST="freedos"
IMAGE_TYPE="iso";;
kolibrios)
GUEST="kolibrios"
IMAGE_TYPE="iso";;
@ -646,11 +643,6 @@ EOF
echo "disk_size=\"64G\"" >> "${CONF_FILE}"
echo "ram=\"4G\"" >> "${CONF_FILE}"
;;
freedos)
echo "boot=\"legacy\"" >> "${CONF_FILE}"
echo "disk_size=\"4G\"" >> "${CONF_FILE}"
echo "ram=\"256M\"" >> "${CONF_FILE}"
;;
kolibrios)
echo "boot=\"legacy\"" >> "${CONF_FILE}"
echo "disk_size=\"2G\"" >> "${CONF_FILE}"
@ -748,13 +740,6 @@ function create_vm() {
${QEMU_IMG} convert -f raw -O qcow2 "${VM_PATH}/${ISO}" "${VM_PATH}/disk.qcow2"
ISO="${ISO/.img/}"
fi;;
freedos)
if [[ ${ISO} = *".zip"* ]]; then
unzip -qo "${VM_PATH}/${ISO}" -d "${VM_PATH}"
rm -f "${VM_PATH}/${ISO}"
ISO="$(ls -1 "${VM_PATH}/"*.iso)"
ISO="$(basename "${ISO}")"
fi;;
kolibrios)
if [[ ${ISO} = *".7z" ]]; then
if [ -z "$(command -v 7z)" ]; then echo $"ERROR! '7zip' needs installing. Unable to extract file."