🐛📝 Fix an error by anti_channel and update documentation.

This commit is contained in:
xtaodada 2022-03-05 21:45:05 +08:00
parent a6eb6ffc3d
commit e815007a87
Signed by: xtaodada
GPG Key ID: 4CBB3F4FA8C85659
2 changed files with 11 additions and 3 deletions

View File

@ -1,6 +1,5 @@
<div align="center">
![STARS](https://img.shields.io/github/stars/Xtao-Labs/iShotaBot?color=yellow&label=Github%20Stars)
![Python](https://img.shields.io/badge/Python-3.9|3.8-blue)
</div>
@ -16,7 +15,14 @@
- 解析 bilibili 视频
- 简易版问与答
Copyright © 2021 Xtao-Labs
## 部署
1. 在 config.gen.ini 中设置 api_id , api_hash
2. 复制 config.gen.ini 为 config.ini
3. 使用 pip 从 requirements 安装所需库
4. ```python3 main.py```
Copyright © 2021-2022 Xtao-Labs
# IDE

View File

@ -1,10 +1,12 @@
import pickle
from os import sep
from os import sep, mkdir
from os.path import exists
def init() -> None:
data = {}
if not exists("data"):
mkdir("data")
if not exists(f"data{sep}anti_channel.pkl"):
with open(f"data{sep}anti_channel.pkl", "wb") as f:
pickle.dump(data, f, pickle.HIGHEST_PROTOCOL)