Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix missing translate api config #47

Merged
merged 1 commit into from
Nov 30, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions config.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,16 @@
from typing import List
from meme_generator.config import meme_config

meme_command_start: str = "" # 命令前缀
memes_prompt_params_error: bool = True # 是否在图片/文字数量不符或参数解析错误时提示(若没有设置命令前缀不建议开启,否则极易误触发)
memes_check_resources_on_startup: bool = True # 是否在启动时检查 `meme-generator` 资源
memes_use_sender_when_no_image: bool = True # 在表情需要至少1张图且没有输入图片时,是否使用发送者的头像(谨慎使用,容易误触发)
memes_use_default_when_no_text: bool = True # 在表情需要至少1段文字且没有输入文字时,是否使用默认文字(谨慎使用,容易误触发)
meme_disabled_list: List[str] = [] # 禁用的表情包列表,填写表情的 `key`

baidu_trans_appid: str = ""
baidu_trans_apikey: str = ""

meme_config.translate.baidu_trans_appid = baidu_trans_appid
meme_config.translate.baidu_trans_apikey = baidu_trans_apikey
meme_config.dump()