File tree 1 file changed +7
-1
lines changed
1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -70,6 +70,12 @@ check_sudo_privileges() {
70
70
install_essential_apps () {
71
71
clear
72
72
73
+ # Check if dialog is installed, and if not, install it
74
+ if ! [ -x " $( command -v dialog) " ]; then
75
+ echo " Dialog is not installed. Installing dialog..."
76
+ sudo apt update && sudo apt install dialog -y
77
+ fi
78
+
73
79
while true ; do
74
80
# Define the dialog menu options
75
81
options=(" 1" " htop - Interactive process viewer" off
@@ -82,7 +88,7 @@ install_essential_apps() {
82
88
" 8" " git - Version control system" off)
83
89
84
90
# Display the dialog menu and store the user's choices
85
- choices=$( dialog --clear --title " Select Essential Apps" --checklist " Choose which essential apps to install:" 0 0 0 " ${options[@]} " 2>&1 > /dev/tty)
91
+ choices=$( dialog --clear --title " Essential Apps Installer " --checklist " Choose which apps to install:" 0 0 0 " ${options[@]} " 2>&1 > /dev/tty)
86
92
87
93
# Check if the user canceled or made no selection
88
94
if [ $? -ne 0 ]; then
You can’t perform that action at this time.
0 commit comments