-
Notifications
You must be signed in to change notification settings - Fork 5
/
run.bat
49 lines (46 loc) · 1.12 KB
/
run.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
@echo off
set FILE=venv\Scripts\activate
if exist horde_module (
goto setup
) else (
echo Downloading horde_module repository...
curl -LJO https://github.com/mak448a/horde_module/archive/refs/heads/main.zip
echo Extracting repository...
powershell -command "Expand-Archive -Path .\main.zip -DestinationPath .\helper_utils\horde_module -Force"
del main.zip
)
:setup
if exist %FILE% (
call venv\Scripts\activate
python main.py
) else (
copy example_config.json config.json
echo > .env
python -m venv venv
call venv\Scripts\activate
pip install -r requirements.txt
set /p TOKEN=Enter your bot token:
echo BOT_TOKEN=%TOKEN% > .env
set /p PRODIA_KEY=Enter your Prodia API Key:
echo PRODIA_KEY=%PRODIA_KEY% >> .env
set /p API_KEY=Enter your API Key:
echo API_KEY=%API_KEY% >> .env
set /p API_KEY=Enter your ChatGPT Key:
echo GROQ_KEY=%API_KEY% >> .env
if [%TOKEN%]==[] (
goto fail
)
if [%TOKEN%]==[] (
goto fail
)
if [%PRODIA_KEY%]==[] (
goto fail
)
if [%API_KEY%]==[] (
goto fail
)
python main.py
)
:fail
echo ERROR! YOU DIDN'T ENTER ALL YOUR CREDENTIALS!
EXIT /b 1