diff --git a/etc/functions b/etc/functions index 401658f..2f67dc2 100644 --- a/etc/functions +++ b/etc/functions @@ -37,8 +37,10 @@ enable_service() { } reset() { - if [ "$1" == "packages" ]; then - function packages() { :; } + if [ "$1" == "config" ]; then + function config() { :; } + elif [ "$1" == "packages" ]; then + function packages() { :; } fi } diff --git a/main.sh b/main.sh index 22ed252..600fb7d 100644 --- a/main.sh +++ b/main.sh @@ -1,10 +1,13 @@ #!/bin/bash +pass="oem" +timezone="Europe/Berlin" + + main="/tmp/vinstall" target="${main}/target" tmp_target="${main}/tmp_target" -pass="oem" -timezone="Europe/Berlin" +vars="${target}/tmp/vinstaller/vars" if [ $DEBUG ]; then umount -R ${target}/boot/efi ${target}/boot ${target}/tmp/vinstaller/ ${target} @@ -350,19 +353,19 @@ do_chroot() { cp -rf $tmp_target ${target}/tmp/vinstaller/run - echo "USERNAME=$USERNAME" > ${target}/tmp/vinstaller/vars - echo "pass=$pass" >> ${target}/tmp/vinstaller/vars - echo "HOSTNAME=$HOSTNAME" >> ${target}/tmp/vinstaller/vars - echo "EFI=$EFI" >> ${target}/tmp/vinstaller/vars - echo "LANGUAGE=$LANGUAGE" >> ${target}/tmp/vinstaller/vars - echo "L1=$L1" >> ${target}/tmp/vinstaller/vars - echo "TARGET_PHY_ID=$TARGET_PHY_ID" >> ${target}/tmp/vinstaller/vars - echo "TARGET_PART=$TARGET_PART" >> ${target}/tmp/vinstaller/vars - echo "TARGETNAME_UNDERSCORE=$TARGETNAME_UNDERSCORE" >> ${target}/tmp/vinstaller/vars - echo "ENCRYPTION_STYLE=$ENCRYPTION_STYLE" >> ${target}/tmp/vinstaller/vars - echo "timezone=$timezone" >> ${target}/tmp/vinstaller/vars - echo "ENC=$ENC" >> ${target}/tmp/vinstaller/vars - echo "HIBERNATE=$HIBERNATE" >> ${target}/tmp/vinstaller/vars + echo "USERNAME=$USERNAME" > ${vars} + echo "pass=$pass" >> ${vars} + echo "HOSTNAME=$HOSTNAME" >> ${vars} + echo "EFI=$EFI" >> ${vars} + echo "LANGUAGE=$LANGUAGE" >> ${vars} + echo "L1=$L1" >> ${vars} + echo "TARGET_PHY_ID=$TARGET_PHY_ID" >> ${vars} + echo "TARGET_PART=$TARGET_PART" >> ${vars} + echo "TARGETNAME_UNDERSCORE=$TARGETNAME_UNDERSCORE" >> ${vars} + echo "ENCRYPTION_STYLE=$ENCRYPTION_STYLE" >> ${vars} + echo "timezone=$timezone" >> ${vars} + echo "ENC=$ENC" >> ${vars} + echo "HIBERNATE=$HIBERNATE" >> ${vars} cat < ${target}/tmp/vinstaller/main_chroot #!/bin/bash @@ -373,6 +376,7 @@ cat < ${target}/tmp/vinstaller/main_chroot for file in \$(find /tmp/vinstaller/run -type f); do . \$file config + reset config done EOF @@ -398,6 +402,7 @@ use_efi encryption_style hibernation user +lang hostname base bootloader