Initial commit: TorrentOps Telegram-controlled qBittorrent RSS rule manager
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,110 @@
|
||||
@echo off
|
||||
title TorrentOps Telegram Bot Setup
|
||||
|
||||
cd /d %~dp0
|
||||
|
||||
echo ==========================================
|
||||
echo TorrentOps Telegram Bot Setup
|
||||
echo ==========================================
|
||||
echo.
|
||||
|
||||
REM ------------------------------------------
|
||||
REM Check Python
|
||||
REM ------------------------------------------
|
||||
|
||||
python --version >nul 2>&1
|
||||
|
||||
if errorlevel 1 (
|
||||
echo Python is not installed or not in PATH.
|
||||
echo Install Python 3.10+ and try again.
|
||||
pause
|
||||
exit /b
|
||||
)
|
||||
|
||||
REM ------------------------------------------
|
||||
REM Create virtual environment
|
||||
REM ------------------------------------------
|
||||
|
||||
if not exist venv (
|
||||
echo Creating virtual environment...
|
||||
python -m venv venv
|
||||
) else (
|
||||
echo Existing virtual environment found.
|
||||
)
|
||||
|
||||
echo.
|
||||
|
||||
REM ------------------------------------------
|
||||
REM Activate virtual environment
|
||||
REM ------------------------------------------
|
||||
|
||||
call venv\Scripts\activate
|
||||
|
||||
echo Virtual environment activated.
|
||||
echo.
|
||||
|
||||
REM ------------------------------------------
|
||||
REM Upgrade pip
|
||||
REM ------------------------------------------
|
||||
|
||||
echo Upgrading pip...
|
||||
python -m pip install --upgrade pip
|
||||
|
||||
echo.
|
||||
|
||||
REM ------------------------------------------
|
||||
REM Install requirements
|
||||
REM ------------------------------------------
|
||||
|
||||
if exist requirements.txt (
|
||||
echo Installing requirements...
|
||||
pip install -r requirements.txt
|
||||
) else (
|
||||
echo requirements.txt not found.
|
||||
)
|
||||
|
||||
echo.
|
||||
|
||||
REM ------------------------------------------
|
||||
REM Create .env if missing
|
||||
REM ------------------------------------------
|
||||
|
||||
if not exist .env (
|
||||
if exist .env.example (
|
||||
echo Creating .env from .env.example...
|
||||
copy .env.example .env >nul
|
||||
) else (
|
||||
echo WARNING: .env.example not found.
|
||||
)
|
||||
) else (
|
||||
echo Existing .env found.
|
||||
)
|
||||
|
||||
echo.
|
||||
|
||||
REM ------------------------------------------
|
||||
REM Create logs directory
|
||||
REM ------------------------------------------
|
||||
|
||||
if not exist logs (
|
||||
mkdir logs
|
||||
)
|
||||
|
||||
REM ------------------------------------------
|
||||
REM Create outputs directory
|
||||
REM ------------------------------------------
|
||||
|
||||
if not exist outputs (
|
||||
mkdir outputs
|
||||
)
|
||||
|
||||
echo.
|
||||
echo ==========================================
|
||||
echo TorrentOps Telegram Bot setup complete.
|
||||
echo ==========================================
|
||||
echo.
|
||||
echo Next step:
|
||||
echo Run run.bat
|
||||
echo.
|
||||
|
||||
pause
|
||||
Reference in New Issue
Block a user