further improvements

This commit is contained in:
David Young
2026-04-09 14:42:39 -06:00
parent bde8ad0c9b
commit 037344eb94
3 changed files with 22 additions and 16 deletions

View File

@@ -28,6 +28,11 @@ print_logo
cd ~
sudo -v
# Keep sudo session alive for the duration of the script
( while true; do sudo -v; sleep 60; done ) &
SUDO_KEEPALIVE_PID=$!
trap "kill $SUDO_KEEPALIVE_PID" EXIT
if ! command -v git &> /dev/null; then
echo "Installing git..."
sudo pacman -S --noconfirm git
@@ -89,18 +94,6 @@ install_packages "${SERVERS[@]}"
cd ~/.local/share/HamPackServer
if [ ! -d "$HOME/.nvm" ]; then
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.3/install.sh | bash
else
echo "nvm is already installed, skipping."
fi
if ! command -v node &> /dev/null; then
nvm install --lts
else
echo "Node.js is already installed, skipping."
fi
if ! pacman -Qi apache &> /dev/null; then
echo "Installing Apache..."
sudo pacman -S --noconfirm apache