-
Notifications
You must be signed in to change notification settings - Fork 5.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
1 changed file
with
59 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
@echo off | ||
setlocal | ||
|
||
:: Title and Description | ||
title MetaGPT Automated Setup | ||
echo =========================================== | ||
echo MetaGPT Automated Setup | ||
echo =========================================== | ||
|
||
:: Check Python installation | ||
echo Checking Python installation... | ||
python --version >nul 2>&1 | ||
if %errorlevel% neq 0 ( | ||
echo Python is not installed. Please install Python 3.9+ and try again. | ||
pause | ||
exit /b 1 | ||
) | ||
|
||
:: Create a Conda environment (if Conda is available) | ||
echo Checking for Conda... | ||
conda --version >nul 2>&1 | ||
if %errorlevel% neq 0 ( | ||
echo Conda not found. Skipping Conda environment creation. | ||
) else ( | ||
echo Creating Conda environment... | ||
conda create -n metagpt python=3.9 -y | ||
conda activate metagpt | ||
) | ||
|
||
:: Install MetaGPT via pip | ||
echo Installing MetaGPT... | ||
pip install --upgrade metagpt | ||
|
||
:: Clone the MetaGPT repository if necessary | ||
if not exist MetaGPT ( | ||
echo Cloning the MetaGPT repository... | ||
git clone https://github.com/geekan/MetaGPT.git | ||
cd MetaGPT | ||
pip install --upgrade -e . | ||
) else ( | ||
echo MetaGPT repository already exists. | ||
cd MetaGPT | ||
) | ||
|
||
:: Initialize MetaGPT config | ||
echo Initializing MetaGPT configuration... | ||
metagpt --init-config | ||
|
||
:: Install additional dependencies | ||
echo Installing additional dependencies from requirements.txt... | ||
pip install -r requirements.txt | ||
|
||
:: Summary | ||
echo =========================================== | ||
echo Setup Completed Successfully | ||
echo =========================================== | ||
pause | ||
|
||
endlocal |