MCP依赖关系安装程序
Node.js、npx和uv的跨平台依赖安装脚本。
支持的操作系统
- Linux(Ubuntu、AlmaLinux/CentOS、Alpine)
- macOS
- 视窗
安装方法
Linux
Ubuntu/Debian
# Download the installation script
curl -O https://raw.githubusercontent.com/yourusername/mcp-depedencies-install/main/install_dependencies.sh
# Make the script executable
chmod +x install_dependencies.sh
# Run the installation script
./install_dependencies.shAlmaLinux/CentOS
# Download the installation script
curl -O https://raw.githubusercontent.com/yourusername/mcp-depedencies-install/main/install_dependencies.sh
# Make the script executable
chmod +x install_dependencies.sh
# Run the installation script
./install_dependencies.shAlpine Linux
# Download the installation script
curl -O https://raw.githubusercontent.com/yourusername/mcp-depedencies-install/main/install_dependencies.sh
# Make the script executable
chmod +x install_dependencies.sh
# Run the installation script
./install_dependencies.shmacOS
# Download the installation script
curl -O https://raw.githubusercontent.com/yourusername/mcp-depedencies-install/main/install_dependencies.sh
# Make the script executable
chmod +x install_dependencies.sh
# Run the installation script
./install_dependencies.sh视窗
# Download the installation script
curl -O https://raw.githubusercontent.com/yourusername/mcp-depedencies-install/main/install_dependencies.sh
# Make the script executable (if using Git Bash or WSL)
chmod +x install_dependencies.sh
# Run the installation script
./install_dependencies.sh先决条件
Linux
curl和sudo安装在您的系统上- 对于Ubuntu/Debian:
apt-get包管理器 - 对于AlmaLinux/CentOS:
dnf或yum包管理器 - 对于Alpine:
apk包管理器
macOS
curl安装在您的系统上- Homebrew(如果不存在,将自动安装)
视窗
- 已安装Windows软件包管理器(winget)
- Git Bash、WSL或PowerShell用于运行脚本
安装什么
该脚本将安装以下依赖项:
- Node.js(v22.x LTS)
- npx(v10.x)
- 紫外线(v0.6.x)
测试
要跨不同环境测试安装脚本,请执行以下操作:
# Make the test script executable
chmod +x test_dependencies.sh
# Run the tests
./test_dependencies.sh这将测试Docker容器中的安装脚本,模拟:
- 乌班图
- AlmaLinux(CentOS)
- Alpine Linux
- macOS
- 视窗
备注
- 该脚本需要Linux系统上的sudo权限
- 安装后,您可能需要重新启动终端以使PATH更改生效
- 对于Linux和macOS用户,该脚本会自动将本地bin目录添加到PATH中
- Windows用户应确保在运行脚本之前安装了Windows软件包管理器(winget)
许可证
\[您的许可证在这里\]

