Expressions/Rules requests (2 Viewers)

apoptygma

Portal Pro
November 14, 2008
160
16
Adelaide
Home Country
I'm after the simplest of simple strings ever really. My shows are named like this

\House\Season 01\S01E01 - Pilot.avi

Then i use a repeat for doubles eg.
\Law and Order\Season 01\S01E01E02 - Hello World.avi

I've currently got two 'simple' rules but they conflict and only work if I disable one or the other so i guess i need to change to regex?
 

zicoz

MP Donator
  • Premium Supporter
  • September 3, 2006
    896
    63
    Home Country
    Norway Norway
    I use these two simple rules for my setup:

    <series>\Season <season>\<series> - S<season>E<episode>-E<episode2> - <title>.<ext>
    <series>\Season <season>\<series> - S<season>E<episode> - <title>.<ext>

    Don't know if it is needed anymore, but when I first made them it seemed to be important to have the one for double episodes above the one for the single episodes in the list of parsing expressions.

    I think this will work for you:

    <series>\Season <season>\S<season>E<episode>E<episode2> - <title>.<ext>
    <series>\Season <season>\S<season>E<episode> - <title>.<ext>
     

    apoptygma

    Portal Pro
    November 14, 2008
    160
    16
    Adelaide
    Home Country
    That's the two rules I have, you're right about the order. The problem is that if they are both enabled then an episode like this:

    \House\Season 01\S01E02 - Hello - World.avi

    For some reason reads as Season "1" Episode ID "2" Episode ID 2 "Hel"
    So it's expecting everything before a - to be episode numbers, how do I get around that problem without renaming every file that has a - in it?
     

    Lehmden

    Retired Team Member
  • Premium Supporter
  • December 17, 2010
    12,554
    3,936
    Lehmden
    Home Country
    Germany Germany
    For some reason reads as Season "1" Episode ID "2" Episode ID 2 "Hel"
    This seems to be a bug in TVSeries plugin. I've recognised this also. Especially the "Hel" as episode ID simply is nothing that should be possible at all. That's why I try to avoid " - " in episodes name by replacing this with "- "... If you have it nevertheless, you can correct this during import in config tool. It's nasty, especially on first import on a fresh DB, but I'm not aware of any other solution atm.
     

    RoChess

    Extension Developer
  • Premium Supporter
  • March 10, 2006
    4,434
    1,897
    There is a single regexp in the exchange forum thread that deals with the show\season\episode structure you both use, which then has no problem (also solves dual-episode problem).
     

    Lehmden

    Retired Team Member
  • Premium Supporter
  • December 17, 2010
    12,554
    3,936
    Lehmden
    Home Country
    Germany Germany
    I also wasn't able to find it.... Tried a lot of the regexp from the thread, but none has solved the issue with " - " in episodes name....
     

    RoChess

    Extension Developer
  • Premium Supporter
  • March 10, 2006
    4,434
    1,897
    Page 3, 1st shared one: (?<series>[^\\$]+)(?:(?:\\(?:confused:eason|Staffel|S[eé]ries?)?[ .-]?[0-2]?[0-9])?\\s?(?<season>[0-2]?[0-9])|\\(?:(?:confused:eason|Staffel|S[eé]ries?)[ .-])?(?<season>[0-2]?[0-9])\\[^\\]*?)[ex]?(?<episode>\d\d+)(?:[ .+-]e?(?<episode2>\d\d+))?(?:[ -]+(?<title>(?![^\\]*?sample)[^$]*?))?\.(?<ext>[^.]*)$

    Expresso INPUT = \House\Season 01\S01E02 - Hello - World.avi

    Expresso RESULT (using same RegExp engine):

    Match Number = 0
    Match Text = "House\Season 01\S01E02 - Hello - World.avi"
    series = "House"
    season = "01"
    episode = "02"
    episode2 = ""
    title = "Hello - World"
    ext = "avi"

    As in perfect match.

    Expresso INPUT = \House\Season 01\S01E02-03 - Hello - World.avi

    episode2 = "03"

    So it is dual-episode compatible.

    Next?
     

    Lehmden

    Retired Team Member
  • Premium Supporter
  • December 17, 2010
    12,554
    3,936
    Lehmden
    Home Country
    Germany Germany
    Hi.
    This one I had tried before, without luck. Not a single match, not even without " - " in episodes name and single episodes files...
    Zwischenablage-1.jpg


    Here it is with my simple expression(s) that has issue with " - " but is working anywhere else.
    Zwischenablage-2.jpg


    These two simple expressions I'm using since many years now:

    1) <series>\Staffel <season>\S<season>E<episode>E<episode2> - <title>.<ext>
    2) <series>\Staffel <season>\S<season>E<episode> - <title>.<ext>

    All my episodes are automatically renamed to match this naming scheme. Dual episode files are captured with the first expression, single episode files with the second... It's reliable as long as no " - " is in episodes name.
     

    Users who are viewing this thread

    Top Bottom