From 0597c5aa131f6cf5dcfba69ca41539874527eeec Mon Sep 17 00:00:00 2001 From: xtaodada Date: Mon, 23 Jan 2023 22:51:49 +0800 Subject: [PATCH] =?UTF-8?q?=E6=89=B9=E9=87=8F=E4=BF=AE=E6=94=B9=E5=B8=AE?= =?UTF-8?q?=E5=8A=A9=E5=8F=82=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- 1A2B/main.py | 2 +- aff/main.py | 2 +- alicloud/main.py | 2 +- atadmins/main.py | 2 +- base64/main.py | 4 ++-- bc/main.py | 2 +- bin/main.py | 2 +- calculator/main.py | 4 ++-- clear_private_chat/main.py | 2 +- covid/main.py | 2 +- da/main.py | 2 +- dictionary/main.py | 2 +- eat/main.py | 2 +- fadian/main.py | 2 +- gfw/main.py | 2 +- google/main.py | 2 +- httpcat/main.py | 2 +- icp/main.py | 2 +- ip/main.py | 2 +- jikipedia/main.py | 2 +- lottery/main.py | 2 +- netease/main.py | 2 +- no_mentions/main.py | 2 +- no_reactions/main.py | 2 +- qr/main.py | 2 +- rate/main.py | 8 ++++---- sb/main.py | 2 +- set_status/main.py | 2 +- silly_girl/main.py | 2 +- sticker/main.py | 2 +- teletype/main.py | 2 +- unban/main.py | 2 +- unixtime/main.py | 2 +- urbandictionary/main.py | 2 +- vctools/main.py | 2 +- vip/main.py | 20 ++++++++++---------- weather/main.py | 2 +- weather_lite/main.py | 2 +- websocket/main.py | 2 +- xtao-some/main.py | 2 +- ytdl/main.py | 2 +- 41 files changed, 55 insertions(+), 55 deletions(-) diff --git a/1A2B/main.py b/1A2B/main.py index 468f1ba..bf0d90d 100644 --- a/1A2B/main.py +++ b/1A2B/main.py @@ -52,7 +52,7 @@ class Game: @listener(command="1A2B", groups_only=True, description="Play a game of 1A2B", - parameters="") + parameters="[start/stop/answer]") async def play_game_1a2b(message: Message): if not message.arguments: return await message.edit("Please specify a command.") diff --git a/aff/main.py b/aff/main.py index 5664e72..2d6082b 100644 --- a/aff/main.py +++ b/aff/main.py @@ -25,7 +25,7 @@ def del_aff() -> None: @listener(command="aff", description="在别人要打算买机场的时候光速发出自己的aff信息(请尽量配合短链接)", - parameters=" (可选,回复一条消息,用于保存|删除aff信息)") + parameters="[save|remove] (可选,回复一条消息,用于保存|删除aff信息)") async def aff(message: Message): if not message.parameter: msg, web_page = get_aff() diff --git a/alicloud/main.py b/alicloud/main.py index 31c980c..78dd65d 100644 --- a/alicloud/main.py +++ b/alicloud/main.py @@ -96,7 +96,7 @@ async def alicloud_startup() -> None: @listener(command="alicloud", description="获取阿里云盘掉落福利信息", - parameters="<订阅/退订>") + parameters="[订阅/退订]") async def set_alicloud_notice(message: Message): if not message.arguments: try: diff --git a/atadmins/main.py b/atadmins/main.py index 52339d6..82039c3 100644 --- a/atadmins/main.py +++ b/atadmins/main.py @@ -7,7 +7,7 @@ from pagermaid.enums import Client, Message @listener(command="atadmins", description="一键 AT 本群管理员(仅在群组中有效)", groups_only=True, - parameters="<要说的话>") + parameters="[要说的话]") async def at_admins(client: Client, message: Message): admins = [] async for m in client.get_chat_members(message.chat.id, filter=ChatMembersFilter.ADMINISTRATORS): diff --git a/base64/main.py b/base64/main.py index c528284..b723877 100644 --- a/base64/main.py +++ b/base64/main.py @@ -6,7 +6,7 @@ from base64 import b64decode, b64encode @listener(command="b64e", description="将文本转为Base64", - parameters="") + parameters="[text]") async def b64e(_: Client, message: Message): msg = message.arguments if not msg: @@ -18,7 +18,7 @@ async def b64e(_: Client, message: Message): @listener(command="b64d", description="将Base64转为文本", - parameters="") + parameters="[text]") async def b64d(_: Client, message: Message): msg = message.arguments if not msg: diff --git a/bc/main.py b/bc/main.py index 8b09048..625ff19 100644 --- a/bc/main.py +++ b/bc/main.py @@ -46,7 +46,7 @@ def init() -> None: @listener(command="bc", description="coins", - parameters=" ") + parameters="[num] [coin1] [coin2]") async def coin(_: Client, message: Message) -> None: """ coin change """ init() diff --git a/bin/main.py b/bin/main.py index 711e6db..33885c7 100644 --- a/bin/main.py +++ b/bin/main.py @@ -11,7 +11,7 @@ import requests @listener(command="bin", description="查询信用卡信息", - parameters="") + parameters="[bin(4到8位数字)]") async def card(_: Client, message: Message): await message.edit('正在查询中...') try: diff --git a/calculator/main.py b/calculator/main.py index 02c8787..a624897 100644 --- a/calculator/main.py +++ b/calculator/main.py @@ -5,7 +5,7 @@ from pagermaid.utils import Message, execute @listener(command="cal", description="计算\n示例:\n`,cal 1+1`加法\n`,cal 2-1`减法\n`,cal 1*2`乘法\n`,cal 4/2`除法\n`,cal 4^2`幂运算\n`,cal sqrt(4)`开方", - parameters="<基本运算>") + parameters="[基本运算]") async def cal(_: Client, message: Message): command = message.arguments if not command: @@ -23,7 +23,7 @@ async def cal(_: Client, message: Message): @listener(command="con", description="换算\n示例:\n`,con 2 99`将99转换为2进制", - parameters="<进制(数字)> <数值>") + parameters="[进制(数字)] [数值]") async def con(_: Client, message: Message): command = message.arguments.split() if not command: diff --git a/clear_private_chat/main.py b/clear_private_chat/main.py index 3e559e3..032ec30 100644 --- a/clear_private_chat/main.py +++ b/clear_private_chat/main.py @@ -27,7 +27,7 @@ async def delete_private_chat(cid: int): @listener(command="clear_private_chat", need_admin=True, description="通过指定关键词清除私聊", - parameters="<关键词>") + parameters="[关键词]") async def clear_private_chat(message: Message): """ 通过指定关键词清除私聊记录 """ if not message.arguments: diff --git a/covid/main.py b/covid/main.py index c5bb0f2..6270e42 100644 --- a/covid/main.py +++ b/covid/main.py @@ -101,7 +101,7 @@ NewsBot = NewsData() @listener(command="covid", description="获取新冠疫情信息。", - parameters="<地区>") + parameters="[地区]") async def covid_info(message: Message): global POLICY_ID, NewsBot if not POLICY_ID: diff --git a/da/main.py b/da/main.py index fd932c0..cd4e816 100644 --- a/da/main.py +++ b/da/main.py @@ -11,7 +11,7 @@ from pagermaid.utils import alias_command groups_only=True, need_admin=True, description="删除群内所有消息。(非群组管理员只删除自己的消息)", - parameters="") + parameters="[true]") async def da(bot: Client, message: Message): if message.arguments != "true": return await message.edit(f"[da] 呜呜呜,请执行 `,{alias_command('da')} true` 来删除所有消息。") diff --git a/dictionary/main.py b/dictionary/main.py index 4f39e35..416e3c6 100644 --- a/dictionary/main.py +++ b/dictionary/main.py @@ -12,7 +12,7 @@ dictionary_data = PyDictionary() @listener(command="dictionary", - parameters="<单词>", + parameters="[单词]", description="查询英语单词的意思") async def get_word_mean(message: Message): """ Look up a word in the dictionary. """ diff --git a/eat/main.py b/eat/main.py index 5c199fa..6fb62e2 100644 --- a/eat/main.py +++ b/eat/main.py @@ -198,7 +198,7 @@ async def downloadFileByIds(ids, context): "当第二个参数是/开头时,在/后面加url则从url下载配置文件保存到本地,如果就一个/,则直接更新配置文件,删除则是/delete;或者/后面加模版id可以手动更新指定模版配置\n\n" "当第二个参数是-开头时,在-后面加上模版id,即可设置默认模版-eat直接使用该模版,删除默认模版是-eat -\n\n" "当第二个参数是!或者!开头时,列出当前可用模版", - parameters=" [随意内容]") + parameters="[username/uid] [随意内容]") async def eat(client_: Client, context: Message): if len(context.parameter) > 2: await context.edit("出错了呜呜呜 ~ 无效的参数。") diff --git a/fadian/main.py b/fadian/main.py index cbd5ae2..b2a9b7e 100644 --- a/fadian/main.py +++ b/fadian/main.py @@ -86,7 +86,7 @@ async def fa_dian_refresher_data(): @listener(command="fadian", description="快速对着指定人物发电", - parameters="") + parameters="[query]") async def fa_dian_process(message: Message): if fa_dian.data.get("date") == 0: await fa_dian.fetch() diff --git a/gfw/main.py b/gfw/main.py index 5b00179..12b141c 100644 --- a/gfw/main.py +++ b/gfw/main.py @@ -28,7 +28,7 @@ async def post(host): @listener(command="gfw", - parameters="", + parameters="[text]", description="查询是否被墙") async def gfw(message: Message): text = None diff --git a/google/main.py b/google/main.py index 3e61e76..9acb519 100644 --- a/google/main.py +++ b/google/main.py @@ -10,7 +10,7 @@ from magic_google import MagicGoogle @listener(command="google", description=lang('google_des'), - parameters="") + parameters="[query]") async def google(message: Message): """ Searches Google for a string. """ query = message.arguments diff --git a/httpcat/main.py b/httpcat/main.py index 9556821..06fd5ec 100644 --- a/httpcat/main.py +++ b/httpcat/main.py @@ -4,7 +4,7 @@ from pagermaid.enums import Client, Message, AsyncClient from pagermaid.listener import listener -@listener(command="httpcat", description="获取 HTTP 状态码的图片。", parameters="") +@listener(command="httpcat", description="获取 HTTP 状态码的图片。", parameters="[http 状态码]") async def httpcat(client: Client, message: Message, request: AsyncClient): try: code = int(message.arguments) diff --git a/icp/main.py b/icp/main.py index d635708..a088346 100644 --- a/icp/main.py +++ b/icp/main.py @@ -56,7 +56,7 @@ async def icp_search(domain): @listener(command="icp", - parameters="<域名>", + parameters="[域名]", description="查询域名是否已备案") async def icp_bei_an(message: Message): url = None diff --git a/ip/main.py b/ip/main.py index a9ae1b2..6a656c5 100644 --- a/ip/main.py +++ b/ip/main.py @@ -36,7 +36,7 @@ async def get_ip_info(url: str) -> str: @listener(command="ip", description="IPINFO (或者回复一句话)", - parameters="") + parameters="[ip/域名]") async def ipinfo(message: Message): reply = message.reply_to_message message: Message = await message.edit('正在查询中...') diff --git a/jikipedia/main.py b/jikipedia/main.py index f459e30..a881acd 100644 --- a/jikipedia/main.py +++ b/jikipedia/main.py @@ -90,7 +90,7 @@ class JIKIPedia: @listener(command="jikipedia", - parameters="<关键词>", + parameters="[关键词]", description="梗查询") async def jikipedia(message: Message): if not message.arguments: diff --git a/lottery/main.py b/lottery/main.py index 32de555..d3cbcdf 100644 --- a/lottery/main.py +++ b/lottery/main.py @@ -102,7 +102,7 @@ async def create_lottery(chat_id: int, num: int, win: int, title: str, keyword: @listener(command="lottery", groups_only=True, need_admin=True, - parameters="<奖品数/人数> <关键词> <标题> / 强制开奖", + parameters="[奖品数/人数] [关键词] [标题] / 强制开奖", description=f"举行抽奖活动\n\n例如:,{alias_command('lottery')} 1/10 测试 测试") async def lottery(message: Message): if not message.arguments: diff --git a/netease/main.py b/netease/main.py index 2fb2a2c..1715201 100644 --- a/netease/main.py +++ b/netease/main.py @@ -74,7 +74,7 @@ async def netease_id(music_id: str, message: Message): @listener(command="netease", description="Netease Music", - parameters="",) + parameters="[query]",) async def netease_music(message: Message): if not message.arguments: return await message.edit(Netease_Help_Msg) diff --git a/no_mentions/main.py b/no_mentions/main.py index 45dd6c0..ac173cf 100644 --- a/no_mentions/main.py +++ b/no_mentions/main.py @@ -12,7 +12,7 @@ no_mentions_sub = Sub("no_mentions") @listener(command="no_mentions", description="自动消除某个对话的 @ 提醒", - parameters="") + parameters="[true|false|status]") async def no_mentions(_: Client, message: Message): if len(message.parameter) != 1: await message.edit(f"[no_mentions] {lang('error_prefix')}{lang('arg_error')}") diff --git a/no_reactions/main.py b/no_reactions/main.py index 0f1eb73..c240a13 100644 --- a/no_reactions/main.py +++ b/no_reactions/main.py @@ -19,7 +19,7 @@ no_reactions_sub = Sub("no_reactions") @listener(command="no_reactions", description="自动已读某个对话的消息表态", - parameters="") + parameters="[true|false|status]") async def no_reactions(_: Client, message: Message): if len(message.parameter) != 1: await message.edit(f"[no_reactions] {lang('error_prefix')}{lang('arg_error')}") diff --git a/qr/main.py b/qr/main.py index 574a01b..8f82d7f 100644 --- a/qr/main.py +++ b/qr/main.py @@ -16,7 +16,7 @@ from pyqrcode import create @listener(is_plugin=False, outgoing=True, command="genqr", description=lang('genqr_des'), - parameters="") + parameters="[string]") async def gen_qr(client: Client, message: Message): """ Generate QR codes. """ text = message.obtain_message() diff --git a/rate/main.py b/rate/main.py index 34df413..1674888 100644 --- a/rate/main.py +++ b/rate/main.py @@ -15,18 +15,18 @@ class Rate: def __init__(self): if Config.LANGUAGE == "en": self.lang_rate = { - "des": "Currency exchange rate plugin", "arg": " ", + "des": "Currency exchange rate plugin", "arg": "[from_] [to_] [NUM]", "help": "Currency exchange rate plugin\n\n" - f"Usage: `,{alias_command('rate')} where is " + f"Usage: `,{alias_command('rate')} [from_] [to_] [NUM] where [NUM] is " "optional`\n\nAvailable currencies: \n", "nc": "is not available.\n\nAvailable currencies: \n", "notice": "Data are updated daily.", "warning": "Data are updated daily."} else: self.lang_rate = { - "des": "货币汇率插件", "arg": " ", + "des": "货币汇率插件", "arg": "[from_] [to_] [NUM]", "help": "这是货币汇率插件\n\n" - f"使用方法: `,{alias_command('rate')} ,其中 是可省略的`\n\n" + f"使用方法: `,{alias_command('rate')} [from_] [to_] [NUM],其中 [NUM] 是可省略的`\n\n" "支持货币: \n", "nc": "不是支持的货币. \n\n支持货币: \n", "notice": "数据每日八点更新", diff --git a/sb/main.py b/sb/main.py index 79e6f63..955c08c 100644 --- a/sb/main.py +++ b/sb/main.py @@ -68,7 +68,7 @@ async def get_uid(chat: Chat, message: Message): description=lang('sb_des'), need_admin=True, groups_only=True, - parameters=" ") + parameters="[reply|id|username>