Skip to content

Commit

Permalink
Update cli.md
Browse files Browse the repository at this point in the history
  • Loading branch information
Soulter authored Dec 15, 2024
1 parent 4e13db7 commit 2d49258
Showing 1 changed file with 16 additions and 4 deletions.
20 changes: 16 additions & 4 deletions deploy/astrbot/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,27 @@ cd AstrBot

```bash
python3 -m venv ./venv
source venv/bin/activate
```

以上步骤会创建一个虚拟环境并激活(以免打乱你电脑本地的 Python 环境),并使用清华大学的镜像源来安装 AstrBot 的依赖。依赖的安装需要花费一些时间。

接下来,通过以下命令安装依赖文件:

```bash
python3 -m pip install -r requirements.txt -i https://mirrors.tuna.tsinghua.edu.cn/pypi/web/simple
```

以上步骤会创建一个虚拟环境(以免打乱你电脑本地的 Python 环境),并使用清华大学的镜像源来安装 AstrBot 的依赖。依赖的安装需要花费一些时间。
> [!TIP]
> 推荐使用更快的 uv 工具来安装依赖文件(平均快 10-100 倍):
> ```bash
> python3 -m pip install uv
> python3 -m uv pip install -r requirements.txt -i https://mirrors.tuna.tsinghua.edu.cn/pypi/web/simple
> ```
接下来,通过以下命令来运行 AstrBot
然后运行 AstrBot
```bash
source venv/bin/activate
python3 main.py
```
Expand All @@ -47,4 +59,4 @@ python3 main.py
> 默认用户名和密码是 `astrbot``astrbot`

接下来,你需要部署任何一个消息平台,才能够实现在消息平台上使用 AstrBot。
接下来,你需要部署任何一个消息平台,才能够实现在消息平台上使用 AstrBot。

0 comments on commit 2d49258

Please sign in to comment.