I am trying to fix a bug in my ServiceInfo.plist file that is causing some problems. I've discovered some new URLs that aren't getting a match.
Here are some example of normal episode URLS:
http://www.crunchyroll.com/[series_name]/episode-[episode_number]-[episode_name_separated_by_dashes]-[episode_id]
With those URLs in mind, Sander came up with the following regex to match URLs for my service:
^http://www.crunchyroll.com/[^/]+/episode\-\d+\-
Since then i've discovered some new URLs (preview videos, not actual full length episodes) being passed that don't match the above regex. These are the URLs causing my URL service problems:
http://www.crunchyroll.com/[series_name]/[series_name]-pv-[episode_number]-[episode_id]
http://www.crunchyroll.com/blast-of-tempest/blast-of-tempest-pv-1-612047
As i'm terrible at regex, i'm having a bit of trouble coming up with a regex that matches the above URLs. Here is my best guess:
^http://www.crunchyroll.com/[^/]+/.+pv\-\d+\-
Any help would be appreciated!
Edit: To clarify, the above string does work, but i'm not sure if it's correct. I just want to make sure i'm not casting the net too wide and matching URLs that aren't exactly what i need.