From 1e7673227823ae99139b00ff7a188a8ad0f5be91 Mon Sep 17 00:00:00 2001 From: sdohuajia <63113882+sdohuajia@users.noreply.github.com> Date: Sun, 27 Oct 2024 21:08:11 +0800 Subject: [PATCH] Update nexus.sh --- nexus.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/nexus.sh b/nexus.sh index 74df28b..ebdb64f 100644 --- a/nexus.sh +++ b/nexus.sh @@ -89,11 +89,17 @@ function start_node() { # 更新系统并安装必要的软件包 echo "更新系统并安装必要的软件包..." - if ! sudo apt update && sudo apt upgrade -y && sudo apt install curl iptables build-essential git wget lz4 jq make gcc nano automake autoconf tmux htop nvme-cli pkg-config libssl-dev libleveldb-dev tar clang bsdmainutils ncdu unzip build-essential -y; then + if ! sudo apt update && sudo apt upgrade -y && sudo apt install curl iptables git wget lz4 jq make gcc nano automake autoconf tmux htop nvme-cli pkg-config libssl-dev libleveldb-dev tar clang bsdmainutils ncdu unzip -y; then echo "安装软件包失败。" # 错误信息 exit 1 fi + # 单独安装 build-essential + if ! sudo apt install build-essential -y; then + echo "安装 build-essential 失败。" # 错误信息 + exit 1 + fi + # 检查并安装 Git if ! command -v git &> /dev/null; then echo "Git 未安装。正在安装 Git..."