mirror of
https://github.com/Kareadita/Kavita.git
synced 2025-07-09 03:04:19 -04:00
Add support for mangapy syntax to parser (#538)
Added support for MangaPy's default naming convention to parser: vol_001-1.cbz
This commit is contained in:
parent
21c204d26f
commit
623105ecd4
1
.gitignore
vendored
1
.gitignore
vendored
@ -499,3 +499,4 @@ _temp/
|
||||
_output/
|
||||
API/stats/
|
||||
UI/Web/dist/
|
||||
/API.Tests/Extensions/Test Data/modified on run.txt
|
||||
|
@ -26,6 +26,7 @@ namespace API.Tests.Parser
|
||||
[InlineData("Akame ga KILL! ZERO v01 (2016) (Digital) (LuCaZ).cbz", "1")]
|
||||
[InlineData("v001", "1")]
|
||||
[InlineData("Vol 1", "1")]
|
||||
[InlineData("vol_356-1", "356")] // Mangapy syntax
|
||||
[InlineData("No Volume", "0")]
|
||||
[InlineData("U12 (Under 12) Vol. 0001 Ch. 0001 - Reiwa Scans (gb)", "1")]
|
||||
[InlineData("[Suihei Kiki]_Kasumi_Otoko_no_Ko_[Taruby]_v1.1.zip", "1")]
|
||||
|
@ -83,6 +83,11 @@ namespace API.Parser
|
||||
@"(?<Series>.*)(\b|_|)(S(?<Volume>\d+))",
|
||||
RegexOptions.IgnoreCase | RegexOptions.Compiled,
|
||||
RegexTimeout),
|
||||
// vol_001-1.cbz for MangaPy default naming convention
|
||||
new Regex(
|
||||
@"(vol_)(?<Volume>\d+)",
|
||||
RegexOptions.IgnoreCase | RegexOptions.Compiled,
|
||||
RegexTimeout),
|
||||
};
|
||||
|
||||
private static readonly Regex[] MangaSeriesRegex = new[]
|
||||
|
Loading…
x
Reference in New Issue
Block a user