mirror of
https://github.com/suikan4github/kaiten-yaki.git
synced 2025-12-20 02:21:17 -03:00
Refactored
This commit is contained in:
parent
3a5446c6ad
commit
d51c88949b
6 changed files with 71 additions and 18 deletions
|
|
@ -3,6 +3,12 @@
|
|||
# Load configuration parameter
|
||||
source config.sh
|
||||
|
||||
# Load functions
|
||||
source common/confirmation.sh
|
||||
source common/preinstall.sh
|
||||
source common/parainstall.sh
|
||||
source common/parainstall_msg.sh
|
||||
|
||||
# Varidate whether script is executed as sourced or not
|
||||
(return 0 2>/dev/null) && sourced=1 || sourced=0
|
||||
if [ $sourced -eq 0 ] ; then
|
||||
|
|
@ -46,7 +52,9 @@ fi # "Void" is not found in the OS name.
|
|||
# *******************************************************************************
|
||||
|
||||
# Common part of the parameter confirmation
|
||||
source common/_confirmation.sh
|
||||
if ! confirmation ; then
|
||||
return 1
|
||||
fi
|
||||
|
||||
# *******************************************************************************
|
||||
# Pre-install stage
|
||||
|
|
@ -61,7 +69,9 @@ else
|
|||
fi
|
||||
|
||||
# Common part of the pre-install stage
|
||||
source common/_preinstall.sh
|
||||
if ! pre_install ; then
|
||||
return 1
|
||||
fi
|
||||
|
||||
# ADD "rd.auto=1 cryptdevice=/dev/sda2:${LUKS_NAME} root=/dev/mapper/${VGNAME}-${ROOTNAME}" to GRUB.
|
||||
# This is magical part. I have not understood why this is required.
|
||||
|
|
@ -75,7 +85,9 @@ sed -i "s#loglevel=4#loglevel=4 rd.auto=1 cryptdevice=/dev/sda2:${LUKS_NAME} roo
|
|||
# *******************************************************************************
|
||||
|
||||
# Show common message to let the operator focus on the critical part
|
||||
source common/_parainstall_msg.sh
|
||||
if ! parainstall ; then
|
||||
return 1
|
||||
fi
|
||||
|
||||
# Ubuntu dependent message
|
||||
cat <<HEREDOC
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue