[mythtv-users] tv_grab_au (1.44... 1.45?)

Phill Edwards philledwards at gmail.com
Fri Dec 2 23:22:56 EST 2005


> > I've updated the script to version 1.44; this one takes the channel
> > names in the config file, eg "Prime Southern", and *matches* against
> > the column header from the web page to determine the appropriate
> > column for that channel. So, "Prime Southern", being a substring of
> > "PRIME SOUTHERN, CANBERRA, WOLLONGONG, STH COAST" still matches this
> > column.
> >
> > The names are used as regular expressions in the match (case ignored),
> > so you could easily modify the config file to make it reasonably
> > resilient to changes in the web page channel names (eg, replace
> > 'southern cross ten capital' with 'ten' or 'capital' etc).
> >
> >   http://www.immir.com/tv_grab_au
> OK, a warning before upgrading to this version, and a request for
> comments...
>
> Some of the channel names in the list at the end of the script contain
> non-alphanumeric characters that have special meanings in regular
> expressions. As a consequence, switching to this version may cause the
> script to fail to match the channel in the config file with the one on
> the web page.
>
> If you're familiar with regular expressions, this is easy to get around.
> Anyone here *not* familiar with regular expressions?
>
> My suggestion: I change the code (for version 1.45 :-)) to check whether
> the channel name is of the form "/regexp/" and in that case do the
> matching; otherwise just do a straight string match as before. So, users
> familiar with editing config files and happy making their own regular
> expressions can easily take advantage of the new feature, while past
> behaviour isn't broken.
>
> Comments? If I don't hear something interesting beforehand I'll release
> another update with this change tomorrow night.

Sounds good.
Regards,
Phill


More information about the mythtv-users mailing list