remove _S_MKFS and rename _S_MKFSAUTO to _S_QUICK_SETUP

This commit is contained in:
Tobias Powalowski 2023-07-17 16:39:30 +02:00
parent b58ec3a623
commit a45cd31968
4 changed files with 14 additions and 19 deletions

View file

@ -6,18 +6,16 @@
# according to partitioning/formatting stage
_auto_fstab(){
# Modify fstab
if [[ -n "${_S_MKFS}" || -n "${_S_MKFSAUTO}" ]]; then
_dialog --infobox "Create new fstab on installed system..." 3 70
if [[ -f /tmp/.device-names ]]; then
sort /tmp/.device-names >>"${_DESTDIR}"/etc/fstab
fi
if [[ -f /tmp/.fstab ]]; then
# clean fstab first from entries
sed -i -e '/^\#/!d' "${_DESTDIR}"/etc/fstab
sort /tmp/.fstab >>"${_DESTDIR}"/etc/fstab
fi
sleep 2
_dialog --infobox "Create new fstab on installed system..." 3 70
if [[ -f /tmp/.device-names ]]; then
sort /tmp/.device-names >>"${_DESTDIR}"/etc/fstab
fi
if [[ -f /tmp/.fstab ]]; then
# clean fstab first from entries
sed -i -e '/^\#/!d' "${_DESTDIR}"/etc/fstab
sort /tmp/.fstab >>"${_DESTDIR}"/etc/fstab
fi
sleep 2
}
# add udev rule for schedulers by default

View file

@ -11,8 +11,7 @@ _VC_NUM="$(basename ${_LOG} | sed -e 's#tty##g')"
_VC="VC${_VC_NUM}"
# install stages
_S_SRC="" # choose mirror
_S_MKFS="" # formatting
_S_MKFSAUTO="" # auto fs part/formatting
_S_QUICK_SETUP="" # guided fs/format
# menu item tracker- autoselect the next item
_NEXTITEM=""
# To allow choice in script set EDITOR=""
@ -134,8 +133,7 @@ _set_guid() {
}
_prepare_storagedrive() {
_S_MKFSAUTO=""
_S_MKFS=""
_S_QUICK_SETUP=""
_DONE=""
_NEXTITEM=""
while [[ -z "${_DONE}" ]]; do
@ -153,12 +151,12 @@ _prepare_storagedrive() {
"4" "Set Filesystem Mountpoints" \
"5" "Return To Main Menu" 2>${_ANSWER} || _CANCEL=1
_NEXTITEM="$(cat ${_ANSWER})"
[[ "${_S_MKFSAUTO}" = "1" ]] && _DONE=1
[[ "${_S_QUICK_SETUP}" = "1" ]] && _DONE=1
case $(cat ${_ANSWER}) in
"1")
_CREATE_MOUNTPOINTS=1
_autoprepare
[[ "${_S_MKFSAUTO}" = "1" ]] && _DONE=1
[[ "${_S_QUICK_SETUP}" = "1" ]] && _DONE=1
;;
"2")
_partition ;;

View file

@ -332,7 +332,6 @@ _mountpoints() {
_dialog --infobox "Devices were mounted successfully." 3 50
sleep 3
_NEXTITEM="5"
_S_MKFS=1
}
# _mkfs()

View file

@ -296,6 +296,6 @@ _autoprepare() {
done
_dialog --infobox "Quick Setup was successful." 3 40
sleep 3
_S_MKFSAUTO=1
_S_QUICK_SETUP=1
}
# vim: set ft=sh ts=4 sw=4 et: