I'm using the following regex to parse my tv series:
However I'm having problems with triple digit episodes:
SeriesName\Season 1\056. Episode.ext
056 is being split into 0 for Season and 56 for Episode, while I need it to be parsed as 056.
I also have some episodes named: s01e10.Title.ext, so I couldn't easily fix this error by removing a part of regex.
I would really appreciate if I could get some help with regex expressions that would cover my files. I tried to find something similar in this thread, but couldn't.
Code:
(?<series>[^\\$]+)(?:(?:\\(?:Season?)?[ .-]?[0-2]?[0-9])?\\s?(?<season>[0-2]?[0-9])|\\(?:(?:Season?)[ .-])?(?<season>[0-2]?[0-9])\\[^\\]*?)[ex]?(?<episode>\d\d+)(?:[ .+-]e?(?<episode2>\d\d+))?(?:[ -.]+(?<title>(?![^\\]*?sample)[^$]*?))?\.(?<ext>[^.]*)$
However I'm having problems with triple digit episodes:
SeriesName\Season 1\056. Episode.ext
056 is being split into 0 for Season and 56 for Episode, while I need it to be parsed as 056.
I also have some episodes named: s01e10.Title.ext, so I couldn't easily fix this error by removing a part of regex.
I would really appreciate if I could get some help with regex expressions that would cover my files. I tried to find something similar in this thread, but couldn't.