💡 add plugin docstring

This commit is contained in:
yanyongyu
2020-10-18 15:04:45 +08:00
parent 26207f762b
commit 7c17412106
9 changed files with 866 additions and 25 deletions

View File

@ -238,6 +238,10 @@ def regex(regex: str, flags: Union[int, re.RegexFlag] = 0) -> Rule:
:参数:
* ``regex: str``: 正则表达式
* ``flags: Union[int, re.RegexFlag]``: 正则标志
\:\:\:tip 提示
正则表达式匹配使用 search 而非 match如需从头匹配请使用 ``r"^xxx"`` 来确保匹配开头
\:\:\:
"""
pattern = re.compile(regex, flags)