summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/core/libs/lib-ui-interactive.sh6
-rw-r--r--src/core/libs/lib-ui.sh2
2 files changed, 6 insertions, 2 deletions
diff --git a/src/core/libs/lib-ui-interactive.sh b/src/core/libs/lib-ui-interactive.sh
index 467be62..e66403a 100644
--- a/src/core/libs/lib-ui-interactive.sh
+++ b/src/core/libs/lib-ui-interactive.sh
@@ -417,7 +417,11 @@ interactive_filesystem ()
[ -n "$fs_mountpoint" ] && default="$fs_mountpoint"
ask_option $default "Select the mountpoint" "Select a mountpoint for $part" required / 'root' /boot 'files for booting' /etc 'config files' /home 'home directories' /tmp 'temporary files' custom 'enter a custom mountpoint' || return 1
fs_mountpoint=$ANSWER_OPTION
- [ "$ANSWER_OPTION" == custom ] && ask_string "Enter the custom mountpoint for $part" "$default" && fs_mountpoint=$ANSWER_STRING || return 1
+ [ "$default" == 'no' ] && default=
+ if [ "$ANSWER_OPTION" == custom ]
+ then
+ ask_string "Enter the custom mountpoint for $part" "$default" && fs_mountpoint=$ANSWER_STRING || return 1
+ fi
fi
# ask label, if relevant
diff --git a/src/core/libs/lib-ui.sh b/src/core/libs/lib-ui.sh
index 5d5e4de..82d11f3 100644
--- a/src/core/libs/lib-ui.sh
+++ b/src/core/libs/lib-ui.sh
@@ -3,7 +3,7 @@
# TODO: implement 'retry until user does it correctly' everywhere
# TODO: at some places we should check if $1 etc is only 1 word because we often depend on that
-# TODO: standardize. eg everything $1= question/title, $2=default
+# TODO: standardize. eg everything $1= question/title, $2=default. also default should probably be 'no' for no default everywhere
# TODO: figure out something to make dia windows always big enough, yet fit nicely in the terminal