Skip to content

Commit

Permalink
Add support for DragonFlyBSD (#378)
Browse files Browse the repository at this point in the history
* Add support for DragonFlyBSD

* Add DragonFlyBSD to README
  • Loading branch information
nqvrg authored Feb 23, 2022
1 parent 86f3d46 commit 4f20194
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 1 deletion.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -215,6 +215,7 @@ Other Operating Systems
- `cachyos` (CachyOS)
- `debian` (Debian)
- `devuan` (Devuan)
`dragonflybsd` (DragonFlyBSD)
- `elementary` (elementary OS)
- `fedora` (Fedora)
- `freebsd` (FreeBSD)
Expand Down
24 changes: 23 additions & 1 deletion quickget
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ function pretty_name() {
archlinux) PRETTY_NAME="Arch Linux";;
arcolinux) PRETTY_NAME="Arco Linux";;
cachyos) PRETTY_NAME="CachyOS";;
dragonflybsd) PRETTY_NAME="DragonFlyBSD";;
elementary) PRETTY_NAME="elementary OS";;
freebsd) PRETTY_NAME="FreeBSD";;
garuda) PRETTY_NAME="Garuda Linux";;
Expand Down Expand Up @@ -161,6 +162,7 @@ function os_support() {
cachyos \
debian \
devuan \
dragonflybsd \
elementary \
fedora \
freebsd \
Expand Down Expand Up @@ -248,6 +250,10 @@ function releases_devuan() {
echo beowulf chimaera
}

function releases_dragonflybsd() {
echo 6.2.1
}

function releases_elementary() {
echo 6.1
}
Expand Down Expand Up @@ -600,6 +606,9 @@ function make_vm_config() {
IMAGE_FILE="${1}"
ISO_FILE="${2}"
case "${OS}" in
dragonflybsd)
GUEST="dragonflybsd"
IMAGE_TYPE="iso";;
freebsd|ghostbsd)
GUEST="freebsd"
IMAGE_TYPE="iso";;
Expand Down Expand Up @@ -646,7 +655,7 @@ EOF
# OS specific tweaks
case ${OS} in
alma|oraclelinux|rockylinux) echo "disk_size=\"32G\"" >> "${CONF_FILE}";;
haiku|openbsd|netbsd|slackware|tails) echo "boot=\"legacy\"" >> "${CONF_FILE}";;
dragonflybsd|haiku|openbsd|netbsd|slackware|tails) echo "boot=\"legacy\"" >> "${CONF_FILE}";;
kolibrios)
echo "boot=\"legacy\"" >> "${CONF_FILE}"
echo "disk_size=\"2G\"" >> "${CONF_FILE}"
Expand Down Expand Up @@ -779,6 +788,19 @@ function get_devuan() {
echo "${URL}/${ISO} ${HASH}"
}

function get_dragonflybsd() {
local HASH=""
local ISO=""
local URL=""

URL="http://mirror-master.dragonflybsd.org/iso-images"
ISO="dfly-x86_64-${RELEASE}_REL.iso"
HASH=$(wget -q -O- "${URL}/md5.txt" | grep "(${ISO})" | cut -d' ' -f4)
web_get "${URL}/${ISO}" "${VM_PATH}"
check_hash "${ISO}" "${HASH}"
make_vm_config "${ISO}"
}

function get_elementary() {
local HASH=""
local ISO="elementaryos-${RELEASE}-stable.20211218-rc.iso"
Expand Down

0 comments on commit 4f20194

Please sign in to comment.