feat: os_basedof function

This commit is contained in:
zen0bit 2024-04-12 18:01:41 +02:00
parent bea27b1ffa
commit c6462e9fa4
1 changed files with 8 additions and 0 deletions

View File

@ -27,6 +27,14 @@ function cleanup() {
fi fi
} }
function os_basedof() {
local SIMPLE_NAME=""
local BASED=""
SIMPLE_NAME="${1}"
BASED=$(os_info "${SIMPLE_NAME}" | cut -d'|' -f2)
echo "${BASED}"
}
if [ "${1}" == '--test-iso-url' ] || [ "${1}" == '-t' ]; then if [ "${1}" == '--test-iso-url' ] || [ "${1}" == '-t' ]; then
test_iso_url="on" test_iso_url="on"
if [ -n "$4" ]; then if [ -n "$4" ]; then