dev:style 项目结构和分类

This commit is contained in:
Wbucket
2026-11-05 22:54:18 +08:00
parent 101d276d9a
commit 6f79cae3a3
3 changed files with 29 additions and 18 deletions
+3 -2
View File
@@ -1,5 +1,7 @@
import re
from astrbot.api import logger
# 输入内容,获取过滤后的字符串与定时秒数
class Pattern:
_pattern = r'<wt>((?!wt).)*</wt>'
@@ -22,7 +24,7 @@ class Pattern:
def load(self,pattern_str:str)->int|None:
content = pattern_str.strip().removeprefix("<wt>").removesuffix("</wt>").strip()
print(content)
try:
num = int(content)
return self.sec_range(num)
@@ -50,4 +52,3 @@ class Pattern:
"content":o_str,
"second":timerSec
}
print(Pattern("awdwadawd<wt>ada</wt>"))