[mythtv-users] automating commercial removal

Chris Pinkham cpinkham at bc2va.org
Wed Sep 26 02:59:07 UTC 2007


* On Tue Sep 25, 2007 at 09:24:27PM -0400, Tom Metro wrote:
> >     #!/bin/sh
> >     mythcommflag --chanid $1 --starttime $2 -V $3
> >     RESULT=$?
> > 
> >     mythcommflag --chanid $1 --starttime $2 -V $3 --gencutlist
> >     exit $?
> 
> What's the purpose of "RESULT=$?" if RESULT is never used?

I thought I said that was untested but maybe I forgot to. :)
I meant to "exit $RESULT" so that the JobQueue gets the result of
the first flagger command not the second.

> > mythcommflag -c %CHANID% -s %STARTTIME% -V %VERBOSELEVEL% ; mythcommflag -c %CHANID% -s %STARTTIME% -V %VERBOSELEVEL% --gencutlist
> 
> I'd substitute && for ;

Agreed but not sure if it will work.  mythcommflag returns the number of
commercial breaks detected as an error code, so && may not work.

Errors are negative, 0 is good, and positive results are number of
breaks flagged.

> True. I guess my ideal would be flipping the behavior and adding a 
> switch to *not* copy the cut list. Copying then becomes the default, and 
> for those users that universally transcode, they can add the option to 
> disable it.

A lot of users don't want to auto-skip though, and copying the
skip list to the cutlist would make everyone autoskip.

--
Chris


More information about the mythtv-users mailing list