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

[web/simple] 允许保存自定义章节识别的正则规则 #534

Closed
RogerProSelf opened this issue May 30, 2024 · 2 comments
Closed

[web/simple] 允许保存自定义章节识别的正则规则 #534

RogerProSelf opened this issue May 30, 2024 · 2 comments
Labels
enhancement New feature or request

Comments

@RogerProSelf
Copy link

RogerProSelf commented May 30, 2024

对于一些固定来源的精校的书,比如知轩藏书上下载的内容,往往有比较固定的正则规则来识别章节效果最好,所以希望能允许更改并保存默认的章节识别规则。

比如我目前给精校书籍使用的:(?<=[ \s]|^)第\s*\d+\s*(?:章|卷).{0,30}(?=\n)|(?<=\n)(?:序|序章|序言|简序|前言|前序|楔子|扉页|引子|引言|卷首语|后记|终章|尾声|后话|大结局|卷末总结|卷末感言|卷末语|间章|同人|番外|里番|外传|外篇|附录|附言|特别章节|上架感言|完本感言|完结感言|作品相关|作者的话|【番外|【里番|【同人|【外传|【IF|【书评:|【作品相关|【设定集).{0,30}(?=\n)

感谢!

@hectorqin hectorqin added the enhancement New feature or request label Jun 1, 2024
@kfab1983
Copy link

kfab1983 commented Jun 6, 2024

因为不能保存,我给输入法添加了自定义短语来输入目录规则

@hectorqin
Copy link
Owner

3.2.9 可以手动创建 storage/data/用户名/txtTocRule.json 文件,内容如下:

[
  {
    "id":1,
    "enable": true,
    "name": "自定义1标题 特殊符号 序号",
    "rule": "^.{1,20}[((][\\d〇零一二两三四五六七八九十百千万壹贰叁肆伍陆柒捌玖拾佰仟]{1,8}[))][  \t]{0,4}$",
    "serialNumber": 17
  }
]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants