mirror of
https://github.com/CerberusV1/minecraft_deploy.git
synced 2026-01-13 11:24:04 +01:00
no input
This commit is contained in:
12
deploy.sh
12
deploy.sh
@@ -57,10 +57,9 @@ rc_local_modified=$?
|
|||||||
|
|
||||||
# If Java or Tmux is not installed, or rc.local is not modified, install/modify
|
# If Java or Tmux is not installed, or rc.local is not modified, install/modify
|
||||||
if [[ $java_installed -ne 0 || $tmux_installed -ne 0 || $rc_local_modified -ne 0 ]]; then
|
if [[ $java_installed -ne 0 || $tmux_installed -ne 0 || $rc_local_modified -ne 0 ]]; then
|
||||||
read -p "Java, Tmux, or rc.local changes are missing. Do you want to install the required programs/make changes now? (y/n): " answer
|
echo "Some required programs or rc.local modifications are missing. Installing..."
|
||||||
|
|
||||||
if [[ "$answer" = "y" ]]; then
|
# Update and install the necessary packages
|
||||||
# Update and install the packages
|
|
||||||
sudo apt update && sudo apt upgrade -y
|
sudo apt update && sudo apt upgrade -y
|
||||||
|
|
||||||
if [[ $java_installed -ne 0 ]]; then
|
if [[ $java_installed -ne 0 ]]; then
|
||||||
@@ -83,10 +82,5 @@ EOL
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
else
|
else
|
||||||
echo "Installation/changes aborted. Exiting script."
|
echo "All required programs are already installed and rc.local is configured. Proceeding..."
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
else
|
|
||||||
echo "All required programs are already installed and rc.local is configured. Proceeding with installation..."
|
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user